hi all,

i have 6 checkboxes, all with the same name but different values. if i want to require that a textbox be required depending on which box was checked, how do i do this?

here is what i have so far....

if ((document.Testform.Principal_Job.checked == true) && (document.Testform.Other_Principal_Job.value == '')){
alert("Please enter text.");
return false;}

Principal_Job is the name of the checkboxes. the value for that box that makes 'Other_Principal_Job' required is 'Other Principal Job'. any suggestions?

hopefully this is all clear