Thanks but I need help with one more thing. If the $totalCost variable is over 200 I need to take the last two digits and multiply it by a different number. Basically I need to make it so that the discount is 7.5% of the price over 100 and 10% of the price over 200. So if they had 199 they would get 99 7.5%. If they had 201 they would get 1 10%.
I have this code so far for this.
if ($totalCost > 100)
{
$discountUR = $totalCost - 100 * 0.075;
$discountVar = (ceil($discountUR/1))* 1;
} elseif ($totalCost > 200)
{
$discountUR = 99 * 0.075;
$discountUR2 = $totalCost - 200 * 0.100;
$discountRnd = (ceil($discountUR2/1))* 1;
$discountVar = $discountRnd + $discountUR2;
}