busillis Posted October 20, 2008 Share Posted October 20, 2008 <script language="javascript"> function changeVisibility(divname) { if (document.getElementById(divname).style.visibility="visible") { document.getElementById(divname).style.visibility="hidden"; alert('hidden'); exit; } else { document.getElementById(divname).style.visibility="visible"; alert('vis'); exit; } } The if clauses don't seem to be working as I would expect (Might be in need of a coffee!)... If I remove both "exit", it will hide and then reshow. Currently, this code will hide the div and then keep it hidden when the link is reinvoked, again stating "hidden"... Any ideas? Many thanks Quote Link to comment Share on other sites More sharing options...
busillis Posted October 20, 2008 Author Share Posted October 20, 2008 Figured this out, forgot to use "==" for comparision! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.