473,395 Members | 1,574 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,395 software developers and data experts.

How to make third radio button option?

Hi,

i'am not so good in php, but i have a script with 2 radio options and i want to make it 3

this are the radio options below third one i made myself the problem is in the php what do i have to add there?

Expand|Select|Wrap|Line Numbers
  1. <img alt="Coco 1" src="coco1.png"   name="bet" id="bet" style="cursor: pointer;" onClick="selects(0);"></td>          
  2.                                     <td align="center" width="44%">          
  3.                                     <img alt="Coco 2" src="coco2.png"   name="bet" id="bet" style="cursor: pointer;" onClick="selects(1);"></td> <td align="center" width="44%">        
  4.                                     <img alt="Coco 3" src="coco3.png"   name="bet" id="bet" style="cursor: pointer;" onClick="selects(2);"></td> 
the php script

Expand|Select|Wrap|Line Numbers
  1. <?php include("setting.php"); ?>
  2. <?
  3.  
  4.     setcookie("wingdtrans","",time()-3600);
  5.  
  6.     $level = $_POST['level'];    //multi purchase option
  7.     $ref = $_GET['ref'];
  8.     $bet = $_POST['bet'];
  9.  
  10.     //do some field checking here
  11.     if ($bet<0 || $bet>1 || $level<1 || $level>$_cost_level) {
  12.         header("Location: index.php");
  13.     }
  14.  
  15.     if ($_usecookie==1) {
  16.         setcookie("wingdtrans","yes",time()+3600);
  17.     }
  18.  
  19. ?>
i (think) i know i have to make the THIRD option somewhere here (see below) but i have no idea what code to use
Expand|Select|Wrap|Line Numbers
  1. if ($bet<0 || $bet>1 || $level<1 || $level>$_cost_level)
hope someone can help me i'am already on this for weeks

i thank you kindly in advance
May 3 '11 #1
1 1706
Dormilich
8,658 Expert Mod 8TB
I’m not sure what you understand by "radio option", but when I think of that, it is something like
Expand|Select|Wrap|Line Numbers
  1. <input type="radio" name="bet" value="1">
  2. <input type="radio" name="bet" value="2">
  3. <input type="radio" name="bet" value="3">
the problems I see in your code:
- duplicate ids. ids must be unique!
- although they can have a name, images ain’t submitted in a form (only form control elements (input, button, textarea) do so.
May 4 '11 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Owen Funkhouser | last post by:
I have a form with three radio options. And I have three buttons: <input type="submit" name="mainform_action" value="Edit Data"> <input type="submit" name="mainform_action" value="View Data">...
1
by: Quiller | last post by:
Hello. I have a group of radio buttons (all with the same name) and I'm trying to set a property of one of them using this code --- document.desc.color.deps = new Array('q10', 'q11', 'q15'); ...
1
by: muralidharan_vak | last post by:
Hi guys, I am using dynamic radio button list using javascript, actually i got a radio list .when i click those buttons ,it doesn't allow to check.please help me resolve this problem.. option...
1
by: Sheau Wei | last post by:
i want to make a search engine for may database. i want to make the radio option at the search engine, but how to handle the search at the radio and the text field
1
by: Scott D Johnson | last post by:
I am using Visual Studio .NET 2003 (I also have VS .NET 2005 installed) I have a group of four radio buttons, and button, to set the first radio button as checked. When I run the app, and say...
3
by: kenia | last post by:
Hi everyone! I'm using the DOM standard to create a set of radio buttons, but I can't select any of them. It means that they appear in the page, but when I click on any of them nothing seems to...
2
by: Eric Layman | last post by:
Hi, I have a radio button and a combo box. Upon changing a value for radio button, the combo box values will be dynamically updated. I have an idea on how to go abt doing it but Im stuck...
4
by: Z.K. | last post by:
I started a forms application and I put on the form three buttons. In the functions for the radio buttons I put in a single messagebox like: MessageBox("Hello 1") MessageBox("Hello 2") ...
4
by: alive84 | last post by:
Hi everyone, I am going nuts with radio/option buttons. Maybe someone can give me a hint how to solve my issue. Problem: I have three fields with radio buttons, External <> Internal <> N/A...
1
by: ahmurad | last post by:
Dear all, I am new group user, computer science graduate; just have joined this established group and thanks to all. I am working in network field but so much interested in web (PHP) field. Recently...
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: 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
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...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

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.