-
Unique Problem
Please help. How can I evaluate in the asp code when a checkbox has been checked or not checked? I know how to set it as checked.
See when a user does a form submit when I gather their data I need to only evaluate what items were checked, not all of the items every time.
Thanks
-
Can't be that unique a problem if you cross posted it.
-
Uhm... and you are asking for help?
-
:D:D:D:D yeah idiot.. j/k
a checkbox is going to return 1 or 0 doesn't matter how it is coded.
-
Try this one:
Code:
test.htm
-----------
<form name=frm action=test.asp method=post>
<input type="checkbox" value="Value1" name="product1">First
<br><input type="checkbox" value="Value2" name="product1">Second
<br><input type="checkbox" value="Value3" name="product1">Third
<br><input type="checkbox" value="Value4" name="product1">Fourth
<input type=submit value=submit>
</form>
test.asp
----------
response.write request.form("product1")
This returns a comma separated string containing the values of the selected products. Mind that i have used the same name "product1" (thats up to u) ..since this would fetch me the selected products at one go. I then manipulate the result using split/join method combination.
- Jemima.