Hi sorry to annoy you AGAIN, but i cant seem to get it working.... i think
its something to do with the order that i put things in:

#end of html and start of php script

#Take the Variables from enterdetails.php that are posted from an html form





$order_value=sprintf('%.2f', floatval($_POST['txtJars'])*7.0);

echo '<INPUT type="hidden" name="testvar" value="'.$order_value.'" />';


# end of php script back into html

Are your details correct?
<td valign="top" colspan="3" align="center"><form action="confirm.php"
method="post"><input type="Submit" name="submit" value="Yes"></form></td>
<td valign="top" colspan="3" align="center"><form
action="updateaddress.php" method="post"><input type="submit"

If i put the echo or INPUT type outside of the php script this works, but
obviously just returns a string '.$quantity.' and not waht the variable
$quantity holds. This is extremely confusing. How do i get this php variable
to be passed to the HTML so it can be posted  I thought the way i have it
the echo would make the variable testvar available to the browser, and then
i would be able to retrieve it by $_POST[testvar]; or $_POST[$testvar]; in
either the confirm.php or updateaddress.php that the html posts to?

Yet again thanks in advance for any help.


Cheers From


PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to