Javascript form submit and radio buttons?


Posted on 16th Feb 2014 07:03 pm by admin

When this form is submitted, it is automatically resubmitted using JS.

All my fields are carried over in the $_post except for total, and state which are radio buttons and a drop down.

Did you know?Explore Trending and Topic pages for more stories like this.
Code: <p><input type="radio" name="Total" value="30" /> 1 Ticket - $30</p>
<p><input type="radio" name="Total" value="50" /> 2 Tickets - $50</p></td>
</tr>
<tr><td><p><strong>First Name:</strong></p>
<p><INPUT TYPE="text" NAME="FirstName" VALUE="<?=$_POST['FirstName']?>"></p></td>
<td><p><strong>Last Name:</strong></p>
<p><INPUT TYPE="text" NAME="LastName" VALUE="<?=$_POST['LastName']?>"></p></td></tr>
Obviously I can't change the value of Total to $_POST['Total'] since that hasn't been set yet. What can I do here?
No comments posted yet

Your Answer:

Login to answer
67 Like 11 Dislike
Previous forums Next forums
Other forums

How could I do this?
Ive got a simple lottery game, and am using an sql database to keep track of the numbers bought. But

What's wrong with my code
sobbing for many days, still don't know why please Help. Why my page isn't posted correctly. In a

Warning: Cannot modify header information - headers already sent by (output sta
Warning: Cannot modify header information - headers already sent by (output started at /home/praylif

Extracting Long text from message class with parameters
Hi,

I would like to extract the long text from a message class. However, the long text ha

modifying a property of an object from a different class
I have 2 classes:
- Math
- Distance

in my math class, I have this line:
$distance =

Registration
ok so i have a site where people can register and login which works now thanks to someone on here th

Check Date/Time in PHP
What I need the code to check is that $reQuest is 24 hours in the past then return a time based on h

LinkedList help
Ok so I just learned quickly about lists, so I have a not too hard project I think, but am having a

single values into sql field
i have a form which i want the user to able to select multiple answers. But i want the answers to be

jquery validation in codeIgniter
hai i need to add client side validation to my fiels which are selected in a forloop.the fields are

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash