jwk811 Posted November 7, 2006 Share Posted November 7, 2006 i will use this as the onClick function:[code]function showHideDiv() { var div = document.getElementById('yourDiv').style; if (div.display == 'block') { div.display = 'none'; } else { div.display = 'block'; }}[/code]so what will i put in the div to make it start off at blocked? Link to comment https://forums.phpfreaks.com/topic/26397-displayblock-div-help-please/ Share on other sites More sharing options...
Telemachus Posted November 7, 2006 Share Posted November 7, 2006 <div style="display: block;" id="yourDiv"> perhaps? Or if you want it to start off at none (totally invisible), <div style="display: none;" id="yourDiv"> Link to comment https://forums.phpfreaks.com/topic/26397-displayblock-div-help-please/#findComment-120714 Share on other sites More sharing options...
jwk811 Posted November 7, 2006 Author Share Posted November 7, 2006 thanks! yeah the display none one worked Link to comment https://forums.phpfreaks.com/topic/26397-displayblock-div-help-please/#findComment-120719 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.