473,385 Members | 1,292 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Radio Button

I have a radio button that i checked depending on a staement. The
problem is that if i want to uncheck it ,it doesnt allow. Is it
possible to uncheck it. heres the code i used for the radio button:
<input type="radio" name="MediaName" value="Others" <% If tel1=tel2
Then %Checked<% End If %>>

Jul 11 '06 #1
3 3625
CJM
"amatuer" <nj*****@gmail.comwrote in message
news:11*********************@m73g2000cwd.googlegro ups.com...
>I have a radio button that i checked depending on a staement. The
problem is that if i want to uncheck it ,it doesnt allow. Is it
possible to uncheck it. heres the code i used for the radio button:
<input type="radio" name="MediaName" value="Others" <% If tel1=tel2
Then %Checked<% End If %>>

<script language="JavaScript">
<!--
function clear_radio_buttons() {
for (var i = 0; i < document.form1.MediaName.length; i++) {
document.form1.MediaName[i].checked = false;
}
}
//-->
</script>
Jul 11 '06 #2
by the looks of it ,i dnt think this will allow me to uncheck wen the
page is running.or will it?
CJM wrote:
"amatuer" <nj*****@gmail.comwrote in message
news:11*********************@m73g2000cwd.googlegro ups.com...
I have a radio button that i checked depending on a staement. The
problem is that if i want to uncheck it ,it doesnt allow. Is it
possible to uncheck it. heres the code i used for the radio button:
<input type="radio" name="MediaName" value="Others" <% If tel1=tel2
Then %Checked<% End If %>>


<script language="JavaScript">
<!--
function clear_radio_buttons() {
for (var i = 0; i < document.form1.MediaName.length; i++) {
document.form1.MediaName[i].checked = false;
}
}
//-->
</script>
Jul 11 '06 #3
CJM

"amatuer" <nj*****@gmail.comwrote in message
news:11**********************@35g2000cwc.googlegro ups.com...
by the looks of it ,i dnt think this will allow me to uncheck wen the
page is running.or will it?
Yes it will, but you need to call the function somewhere within your page. I
would suggest a standard link.
Jul 11 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Oscar Monteiro | last post by:
I Have to sets of Radio buttons like so: <input type="radio" name=p1 value=1> <input type="radio" name=p1 value=2> <input type="radio" name=p1 value=3> <br> <input type="radio" name=p2 value=1>...
5
by: Digital Puer | last post by:
I have the following HTML form: - radio button A (default selected) - radio button B - input field, of type "file" with "Choose" button - submit button I would like to have it so that if the...
3
by: John Davis | last post by:
I created a ASP.NET Web Form using VB.NET with a text box, 2 radio buttons. When the user click the first radio button, the text will change to uppercase. If the user clicks the other radio button,...
3
by: Amelyan | last post by:
When we want radio button to belong to a group name we say, radio1.GroupName="GroupA". In this case, radio1 will be unselected if another radio button is selected in "GroupA". Is there a way...
8
by: David Cameron | last post by:
I noticed that using an HTMLInputRadioButton and specifying a value to be an empty string (""), this is overridden by ASP.Net which set the value of the control to be the same as the ID of the...
1
by: Joe Attardi | last post by:
Hi all, On a form on one of my pages I have two <select> elements, and each one is paired up with a radio button. The idea is to choose an item from one list or the other and select the radio...
9
by: IchBin | last post by:
I can not see what the problem is with this script. I am just trying to set a radio button by calling setCheckedValue('abbr_letter', 'V'). Sorry I am new to javascript. <html> <head> <script...
10
by: IchBin | last post by:
I am trying to set the state of a radio button. I do not see what I am doing wrong. Sorry, I am new at this.. I need another set of eyes to look at this snip of code. I am trying to set the radio...
0
by: jehugaleahsa | last post by:
Hello: I have radio buttons bound to boolean properties in a business object. private void bindRadioButton(RadioButton button, string propertyName) { Binding binding =...
8
by: photoboy | last post by:
I have racked by brain long enough on this, so now I need the help of someone who knows what they are doing. Here is what I am trying to achieve: First, I have two radio buttons (both unchecked)...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.