Click to See Complete Forum and Search --> : Radio Select problem


florida
04-10-2003, 12:50 PM
I have an update form that comes up with an "Approved" and "Disapproved" radio selection. It works but I dont like how it automatically checks the "Disapproved" button when the form comes up for the first time. I was hoping the form would come up with "Approved" and "Disapproved" not selected so it allows me to make a selection of one of the two selections. Please advise how I can correct this using Javascript instead of Cold Fusion because I cant get it to work.



APPROVED
<INPUT TYPE="radio" NAME="approved" VALUE="1" <CFIF #myquery.approved# Is 1>CHECKED</CFIF>>

DISAPPROVED
<INPUT TYPE="radio" NAME="approved" VALUE="0" <CFIF #myquery.approved# Is 0>CHECKED</CFIF>>

Nevermore
04-10-2003, 12:57 PM
Seems fine to me - do you have a working example?

florida
04-10-2003, 01:15 PM
It doesnt seem to work for me. It shows the 'Disapproved' button selected all the time unless I select the 'Approved' button. But I need it to show both NOT selected the first time the form comes up.

khalidali63
04-10-2003, 05:28 PM
To make a radio button not checked bu default ,typical code will look like this

<INPUT TYPE="radio" NAME="approved" VALUE="1" checked="checked">CHECKED>
Now you have to make sure that the coldfusion code you insert, is not adding checked="checked" attribute in the above tag description

Cheers

Khalid