Author: costinvint | Posted on: 1/16/2010 3:30:19 PM | Views : 395

Hi-- My button toggles the display of a <div> tag and it works fine except for the first time its clicked. The first time its clicked the button (and the table its in ) just moves up alittle and doesnt work.  The 'div' starts of hidden:
<div id="tbl" style="display:none">  And the button looks like this:
<input type="button" id="btnVars" value="Variables" title="Click to see list of available variables." onclick="var tbl=document.getElementById('tbl');if(tbl.style.display=='none'){tbl.style.display='inline';}else{tbl.style.display='none';}"/>
The whole thing is in a form, and it doesnt postback ...

Go to the complete details ...