PDA

View Full Version : Server Side Radio Group Validation?


AbsolutMauser
07-11-02, 05:35
I am creating a form which will update an existing record in an Access table. I am using the Request object with Form to validate all my text boxes. However, I am at a loss as to how to use Request.Form to validate a checkbox. The client side method of:

for (i = 0; i < radioGroup.length ; i++){
if (!radioGroup[i].checked == '1') errorString += "No item selected";
}

does not seem to work because the Request object is not the same as a a simple form object on the client side.

Does anyone know a good way of performing server side radio group validation?

Thx,

~AbM

buddu
07-26-02, 02:29
hi
if you are using Checkboxes /Radio buttons you need to validate as follows

reqest.form("chkbox/radiobtn")="on"

try using "on" option.

EvE
08-21-02, 09:18
Or try this:

<input type="radio" name="col1" value="1" <%=col1%>>
<input type="radio" name="col1" value="0" <%=col2%>>



if rs("col1") = TRUE then
col1= "CHECKED"
col2 = ""
else
col1= ""
col2 = "CHECKED"
end if