Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Apr 16th, 2005, 12:05 AM   #1
Navid
Hobbyist Programmer
 
Navid's Avatar
 
Join Date: Feb 2005
Location: Canada
Posts: 187
Rep Power: 4 Navid is on a distinguished road
Send a message via MSN to Navid
Radio

<html>
<form>
<input type="radio"> <input type="radio">
</form>
</html>

How do I get it to alternate the "radios" when I click them?

Last edited by navnav; Apr 16th, 2005 at 5:23 PM.
Navid is offline   Reply With Quote
Old Apr 16th, 2005, 12:08 AM   #2
Navid
Hobbyist Programmer
 
Navid's Avatar
 
Join Date: Feb 2005
Location: Canada
Posts: 187
Rep Power: 4 Navid is on a distinguished road
Send a message via MSN to Navid
Sorry for the double topic, I thought it screwed up the first time and didnt get posted.
Navid is offline   Reply With Quote
Old Apr 16th, 2005, 5:29 AM   #3
kirkl_uk
Programmer
 
kirkl_uk's Avatar
 
Join Date: Apr 2005
Location: England
Posts: 86
Rep Power: 4 kirkl_uk is on a distinguished road
Send a message via MSN to kirkl_uk
From what I can remember, give both input types the same name, but a different value.

<input type="radio" name="gameType" value="action">
<input type="radio" name="gameType" value="shooter">

Let me know if this works, as I can't quite remember.

kirkl_uk
kirkl_uk is offline   Reply With Quote
Old Apr 16th, 2005, 12:39 PM   #4
Navid
Hobbyist Programmer
 
Navid's Avatar
 
Join Date: Feb 2005
Location: Canada
Posts: 187
Rep Power: 4 Navid is on a distinguished road
Send a message via MSN to Navid
it worked

thanks

Were you unsure because you use XHTML now, or you just havent used HTML in a while?

Is there anything you could do with XHTML that you can't do with HTML?

Last edited by navnav; Apr 16th, 2005 at 12:51 PM. Reason: Question
Navid is offline   Reply With Quote
Old Apr 16th, 2005, 2:33 PM   #5
bl00dninja
Programming Guru
 
bl00dninja's Avatar
 
Join Date: Oct 2004
Location: namespace std
Posts: 1,246
Rep Power: 6 bl00dninja is on a distinguished road
initially you created two separate radio buttons. the one that worked created one set of radio buttons with two choices, which is what you must do. you can have 500 radio buttons that only select one choice, but you have to initialize that radio button and define the instances of it like he said above.
__________________
i put on my robe and wizard hat...

Have you ever heard of Plato, Aristotle, Socrates?...Morons.
bl00dninja is offline   Reply With Quote
Old Apr 16th, 2005, 2:35 PM   #6
bl00dninja
Programming Guru
 
bl00dninja's Avatar
 
Join Date: Oct 2004
Location: namespace std
Posts: 1,246
Rep Power: 6 bl00dninja is on a distinguished road
Quote:
Is there anything you could do with XHTML that you can't do with HTML?
xhtml 1.0 is essentially the current version of html with all those type declarations and crap (transitional, etc.). there is little difference. xhtml is now html, however most browsers are backwards-compatible with older versions of the language.
__________________
i put on my robe and wizard hat...

Have you ever heard of Plato, Aristotle, Socrates?...Morons.
bl00dninja is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 10:49 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC