RE: setting div visibility with javascript

2008-10-10 Thread Craig Dudley
You shouldn't do. What's going wrong in your example? -Original Message- From: Scott Stewart [mailto:[EMAIL PROTECTED] Sent: 10 October 2008 15:19 To: cf-talk Subject: SOT: setting div visibility with javascript Hey all, If I'm setting the visibility for a div (display:none or

Re: setting div visibility with javascript

2008-10-10 Thread Scott Stewart
It's complicated: here's the template: http://cfm.pastebin.com/m549bfe76 what I'm specifically dealing with is function Q4Chk(i), which sets display settings based on the input from a set of radio buttons (note: I didn't write this, but I'm trying to get it to work properly) The business logic

RE: setting div visibility with javascript

2008-10-10 Thread Craig Dudley
could be wrong though. -Original Message- From: Scott Stewart [mailto:[EMAIL PROTECTED] Sent: 10 October 2008 15:59 To: cf-talk Subject: Re: setting div visibility with javascript It's complicated: here's the template: http://cfm.pastebin.com/m549bfe76 what I'm specifically dealing

Re: setting div visibility with javascript

2008-10-10 Thread Scott Stewart
It's complicated: here's the template: http://cfm.pastebin.com/m549bfe76 What I'm specifically dealing with is function Q4Chk(i), which sets display settings based on the input from a set of radio buttons (note: I didn't write this, but I'm trying to get it to work properly) The business logic

Re: setting div visibility with javascript

2008-10-10 Thread Peter Boughton
here's the template: http://cfm.pastebin.com/m549bfe76 You really should investigate jQuery. It will allow you to ditch all this ugly overly-verbose code: document.getElementById(COMMENTB).style.display = none; document.getElementById(COMMENTC).style.display = none;

Re: setting div visibility with javascript

2008-10-10 Thread Scott Stewart
here's the template: http://cfm.pastebin.com/m549bfe76 You really should investigate jQuery. It will allow you to ditch all this ugly overly-verbose code: document.getElementById(COMMENTB).style.display = none; document.getElementById(COMMENTC).style.display = none;

Re: setting div visibility with javascript

2008-10-10 Thread Scott Stewart
Umm, it might be as simple as the JS not setting the display property correctly? e.g. document.getElementById(COMMENTB).style.display = none; document.getElementById(COMMENTC).style.display = ''; document.getElementById(FRMSUBMIT).style.display = ''; Shouldn't the empty quotes be 'block' ? I