Check Box (Full Version)

All Forums >> [Web Development] >> Dreamweaver Help



Message


climberman -> Check Box (12/23/2007 20:49:09)

When a person puts a check in the box can you have the answer be something other then Y or N in the data base. It seems like I have changed that before but I can't remember now how I did it.

Thanks




swoosh -> RE: Check Box (12/23/2007 22:10:49)

Wouldn't just changing the "value" of the checkbox do it?




climberman -> RE: Check Box (12/23/2007 22:45:15)

That is what I thought so maybe I am doing something wrong. I changed the value but it doesn't work




rdouglass -> RE: Check Box (12/24/2007 2:27:25)

Checkboxes work in the sense that there is either a value or there is not; there cannot be 2 different values directly from 1 checkbox.

<input type="checkbox" name="mycheckbox" value="yes">

When you Request.form("mycheckbox"), you will either get "yes" or Null . If you want a "no" out of it, you need to do something like:

<%IF trim(Request.form("mycheckbox") & "") = "yes" Then
myValue = "yes"
ELSE
myValue = "no"
End IF%>

Hope it helps.




climberman -> RE: Check Box (12/24/2007 9:39:32)

Thanks everyone I will work on it tonight.




climberman -> RE: Check Box (12/24/2007 11:24:24)

Here is the code I have and all I get is a Y or an N

<input name="WillingToRelocate" type="checkbox" value=yes>




Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
0.046875