I have a function that hides / shows the table by clicking on the top that I have more than one table and you want to use only one function for each table instead of writing it. To do this, I am trying to pass arguments (this, this.lastSibling). For some reason this.last symbolizing is not targeting any object. I have tried every way to navigate the node tree, but I can think of it, but I can not make my goal. My Javascript / JQuery My HTML Thanks advance! I have a function that hides / shows a table by clicking on a top A I lost your current code but if you want to toggle the visibility of the dibbling (or the last element in your Live sample: & gt; Tag When the table is hidden and the remaining skip header, which can be hidden from the table by clicking again.
Function Toggletable (Triggers, Goals) {$ (Triggers) Click (function () {$ (target) toggle (); toggletable (trigger, target)}); }
& lt; Table class = "format 2" & gt; & Lt; Thead onmouseover = "toggletable (this, this.last sibling)" & gt; & Lt; -! Title - & gt; & Lt; / Thead & gt; & Lt; Tbody & gt; & Lt ;! - Cells with information here - & gt; & Lt; / Tbody & gt; & Lt ;! - Note no TFooter tag - & gt; & Lt; / Table & gt; & Lt; - Other tables similar to the one above - & gt;
& lt; Thead & gt; The tag is hidden in the tag when the table is hidden and the left is the left header, which can be hidden from the table by clicking again.
& lt; table & gt; tag) You can try it.
Function ready () {$ ('Table & gt; thead') .each (function (e) {$ (this) .siblings ( ': Last'). Hide ();} .click (function (e) {$ (this)) toggle ();});} $ (ready);
Comments
Post a Comment