I'm sure someone will help with this:

Basically I got a form which on submit, it directs it to my contact_form.asp which then sends out an email to a specified address, well I got some Radio buttons on that form, and need to get the checked radio button out of a group of about 3 radio buttons.

i.e.

<input type="radio" name="group1" value="Daily"> Daily </input> <input type="radio" name="group1" value="Weekly"> Weekly</input> <input type="radio" name="group1" value="Monthly"> Monthly</input> 

and in my contact_form.asp I am requesting the value like:

group1 = Request("group1") 

Am I doing something wrong? i.e. getting the value incorrectly? The response I'm getting is "Group1", not "Daily" as I want to.

1 Answer

I created a test page using the code you supplied and it works fine (see below).

Try a http debugging tool such as fiddler2 to investigate the actual parameters and values passed between the two pages.

<html> <head></head> <body> <form method="post"> <input type="radio" name="group1" value="Daily"> Daily </input> <input type="radio" name="group1" value="Weekly"> Weekly</input> <input type="radio" name="group1" value="Monthly"> Monthly</input> <input type="submit" value="submit" /> </form> </div> <% Dim group1 group1 = Request("group1") Response.Write ("group1='" + group1 + "'") %> </body> </html> 
1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy