Hi .....
Can anyone help ?
I am trying to write a javascript that will allow a form to have several different part to it, selectable by tick boxes eg
Top section of form = Name, Dept , etc
Thene there would be sveral tick boxes eg NT Account , Lotus Notes Account , Novell Account
If they tick Novell and NT the relevent part of the form open up ... I have worked on an example but because I am using <div visibilty:hidden> I get big gaps in the form ...... any ideas
demo
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
<TITLE></TITLE>
<SCRIPT LANGUAGE=javascript>
<!--
function hideText(){
if(document.forms[0].checkbox1.checked){
document.getElementById("formitem").style.visibility="hidden"
}else{
document.getElementById("formitem").style.visibility="visible"
}
}
//-->
</SCRIPT>
<SCRIPT LANGUAGE=javascript>
<!--
function hideText2(){
if(document.forms[0].checkbox2.checked){
document.getElementById("formitem2").style.visibility="hidden"
}else{
document.getElementById("formitem2").style.visibility="visible"
}
}
//-->
</SCRIPT>
</div>
</HEAD>
<BODY>
Thanks Andy
Can anyone help ?
I am trying to write a javascript that will allow a form to have several different part to it, selectable by tick boxes eg
Top section of form = Name, Dept , etc
Thene there would be sveral tick boxes eg NT Account , Lotus Notes Account , Novell Account
If they tick Novell and NT the relevent part of the form open up ... I have worked on an example but because I am using <div visibilty:hidden> I get big gaps in the form ...... any ideas
demo
<HTML>
<HEAD>
<META NAME="GENERATOR" Content="Microsoft Visual Studio 6.0">
<TITLE></TITLE>
<SCRIPT LANGUAGE=javascript>
<!--
function hideText(){
if(document.forms[0].checkbox1.checked){
document.getElementById("formitem").style.visibility="hidden"
}else{
document.getElementById("formitem").style.visibility="visible"
}
}
//-->
</SCRIPT>
<SCRIPT LANGUAGE=javascript>
<!--
function hideText2(){
if(document.forms[0].checkbox2.checked){
document.getElementById("formitem2").style.visibility="hidden"
}else{
document.getElementById("formitem2").style.visibility="visible"
}
}
//-->
</SCRIPT>
</div>
</HEAD>
<BODY>
Thanks Andy