Forum Moderators: coopster
[2]
if ($total > 81.75)
{printf ("%01.2f", $total * .11);}
else {echo "8.99 ";}
[/2] I have a field for '$shipcountry' - the new condition needs to identify whether the order is being shipping with USA or goes to another country... :
something like....
[2]
IF $shipcountry = "USA",
THEN DO USE CODE ABOVE
ELSE $total * .25
[/2] It looks like a couple of IFs AND then ELSE to me...just wish I knew how to write it...
any help appreciated in advance..
mc
I am also guessing you want all of the first code in your if and only the multiplication in your else therefore
if ($shipcountry == "USA") {
if ($total > 81.75) $ship = $total * .11;
else $ship = '8.99';
} else {
$ship = $total * .25;
}
echo $ship,' '; something like that?