Saturday, August 21, 2010

PHP syntax and structure for radio button and its values

Programmer Question

Radio box code:



Apples />

Oranges


$choice=array("A"=>1.00, "B"=>0.80);
echo $choice["A"]; // will give me the value of 1.00
echo $choice["B"]; // will give me the value of 0.80


Given the code snippet above, is there anything wrong in terms of either the HTML radio box, the array or the choices?



Find the answer here

No comments:

Post a Comment

LinkWithin

Related Posts with Thumbnails