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.

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

opening a window with after form submission
I know this this forum has nothing to do with JS, but i'm trying to use it with my php script.
<

Php - mysql store data and use it later?
Hi, i' making a login page at the moment, however my username + password is stored many different pl

Hyperlink is adding an extra gap to variable
Hi, here's my problem..

I have a php generated page with a hyperlink which opens in a new win

Help with Password Encoding/Decoding?
Trying to design a "change password" tool. On my signup code I'm using base64_encode, now

Character increment
Hi,

I am facing a scenario like above,but in my case i want to show up like Col A,Col B etc..

Setting a default timezone?
I have read about how to change the timezone in PHPMYADMIN, but it changes back, it doesn't STAY the

Connecion issue
Hi,

For some reason, I keep getting this error when trying to connect:

Warning: mysql_

Strange php code found on my website
I got hacked and the following code was placed within my files:

Code: [Select]<?
/*

PayPal Redirect Issue
When I have my paypal button set so that is redirects to http://empiremarketing.ca/order.php,it work

How to disable direct access to a file
Suppose I've 2 Files. 1.php & 2.php

I don't want anybody to access 2.php directly fr

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