Search the archives!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Javascript] hidden check box element
- From: javascript@xxxxxxxxxx (Tom Wheeler)
- Subject: [Javascript] hidden check box element
- Date: Fri, 28 Dec 2001 08:02:04 -0800
This works in IE, but in Netscape I think the only way to do this is to
enclose the form in a <DIV>, and then access its style properties. If
anyone has other info I would like to know.
<SCRIPT Language="JavaScript">
function showElement(toggle) {
if (toggle == 'on') document.theForm.theCheckBox.style.visibility =
'visible';
if (toggle == 'off') document.theForm.theCheckBox.style.visibility =
'hidden';
}
</SCRIPT>
<FORM name="theForm">
<input type="checkbox" style="visibility:hidden" name="theCheckBox">
Are you there?
<P>
<A HREF="javascript:showElement('on')">show checkbox</A>
<A HREF="javascript:showElement('off')">hide checkbox</A>
</FORM>
M. Amin wrote:
Dear All,
in my html file i set a check box hidden as <input type=checkbox
style=visibility:hidden >........
and i'd like to trigger its visibility property using java script or by
using any solving idea.
Any help will be appreciated,
Regards,
M. Amin
- Follow-Ups:
- [Javascript] Netscape 4x and text form fields
- From: Nancy Burton-Vulovic
- [Javascript] Netscape 4x and text form fields
- Prev by Date: [Javascript] Something OT
- Next by Date: [Javascript] server-side js
- Previous by thread: [Javascript] Something OT
- Next by thread: [Javascript] Netscape 4x and text form fields
- Index(es):