Jump to content

newb attempting to make form


zeem

Recommended Posts

ive been trying to make a for that you can enter ur billing information, and if its different from the shipping , it will show it. like any type of orderform.

this is a snipit of my code:

<p><?php echo $city?>

<P><h3>Billing Address<font size=1>(if different from above)</font>*</h3></p>

<?php $_POST["sadr"];

if (sadr == ""){

$sadr = $adr;

$scity = $city;

$sstate = $state;

$szip = $zip;

$scountry = $country;

$sdphone = $dphone;

$sephone = $ephone;

echo "Address:". $sadr;

echo "City:". $scity;

echo "State:".$sstate;

echo "Zip Code:".$szip;

echo "Day Phone(with area code 4011234567):".$sdphone;

echo "Evening Phone:".$ephone;

}

else{

$_POST["sadr"];

$_POST["scity"];

$_POST["sstate"];

$_POST["szip"];

$_POST["sdphone"];

$_POST["sephone"];

}

$_POST["note"];

?>

<p> Address: <?php echo $sadr;?>

<p> City: <?php echo $scity;?>

<p> State: <?php echo $sstate;?>

<p> Zip : <?php echo $szip;?>

<p> Day Phone <?php echo $dphone;?>

<p> Evening Phone <?php echo $ephone;?>

<p> Note: <?php echo $note?>

 

 

 

i am asuming that my method of getting variables is off. I used $_post to get them, was that wrong?

Link to comment
https://forums.phpfreaks.com/topic/41137-newb-attempting-to-make-form/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.