i corrected the code to set the error to:
<?php
if(isset($_POST['Coupon_Code'])) {
if(($_POST['Coupon_Code'] == "airflight") || ($_POST['Coupon_Code'] == "facebook") || ($_POST['Coupon_Code'] == "pinterest")) {
$_SESSION['badCoupon'] = "yes"; }
else {
$_SESSION['badCoupon'] = "no";
}
}
?>
i also moved it up to line 49.
I corrected the code to show the error to:
<?php if(isset($_SESSION['badCoupon']) && ($_SESSION['badCoupon'] == "no")) echo "You entered an invalid coupon code."; ?>