Forum Moderators: coopster
I've been trying to use if-then statements like this:
if ($option1 == "yes")
{$price += 5}
Anyway, it's not working AT ALL and causing the entire php file to stop functioning. ANY help at all would be so greatly appreciated... especially help on applying this if-then to all three options.. Thanks so much!
<input type="hidden" name="price" value="55.00">
Optional Features:<br />
Gold Clasps:<input name="gclasps" type="checkbox" class="oform" value="yes" /><br />
Silver Clasps:<input name="sclasps" type="checkbox" class="oform" value="yes" />
And here is the relevant PHP:
$price=$_POST['price'];
$gold_clasps = $_POST['gclasps'];
$silver_clasps = $_POST['sclasps'];
if($gclasps == "yes"){
$price =+ 5.00
}
Huge mistakes?