----- Original Message -----
From: "Bj"
Actually that looks too complicated to follow, so here's an example script.
Say you have a form
<form name="boxform" onsubmit="javascript:chk();">
and in this form you have an arbitrary number of checkboxes each called
'opt[]':
Then in the head of the page you put this script:
<script>
function chk() {
boxes = boxform.elements['opt[]'];
l = boxes.length;
msg = '';
for (i=0; i<l; i++)
if (boxes[i].checked) msg += 'Box ' + (i+1) + ' is checked\n';
if (msg == '') msg = 'No boxes were checked';
alert(msg);
}
</script>
When you submit the form you'll get a Javascript alert telling you which
boxes were ticked or that none was ticked.
____ � The WDVL Discussion List from WDVL.COM � ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED]
Send Your Posts To: [EMAIL PROTECTED]
To set a personal password send an email to [EMAIL PROTECTED] with the words: "set
WDVLTALK pw=yourpassword" in the body of the email.
To change subscription settings to the wdvltalk digest version:
http://wdvl.internet.com/WDVL/Forum/#sub
________________ http://www.wdvl.com _______________________
You are currently subscribed to wdvltalk as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]