separating radio buttons in a page

how do i separate radio buttons in a single page…i know that frames work in vb but i dont know how to separate radio buttons in php in a single page…can somebody please help…im new to php

Just to clear something up, which I’m sure you already knew, but it is a concept that I think a lot of people just don’t understand. It’s all just HTML. Whether it is php, java, vb or c# it all comes out as HTML.

I recommend you use google and first search for “HTML radio button tutorial” and that will clear up a lot. I will however attempt to answer your question:

with html you group radio buttons by “name”. So if I have 3 radio buttons all named “rdoJim”:

<input type="radio" name="rdoJim" value="one" /> One<br />
<input type="radio" name="rdoJim" value="two" /> Two<br />
<input type="radio" name="rdoJim" value="three" /> Three

When you select one all others will be deselected and then if you select another one the same thing will happen, all others will be deselected. Then when you post it, the item located in the value property of the selected radio button is what will be posted and can be reference by $_GET[‘rdoJim’] if you are using a GET method or $_POST[‘rdoJim’] if you are using a POST method.

Sponsor our Newsletter | Privacy Policy | Terms of Service