if ($varCheckCoupon) { header('location:coupon_frm_uil.php'); die; } else { $varEditCoupon = $objCoupon->editCoupon($_POST); if ($varEditCoupon) { $objCore->setSuccessMsg(ADMIN_UPD_COUPON_SUCC_MSG); header('location:' . $_SESSION['sessLastCouponPage']); die; } else { header('location:coupon_frm_uil.php'); die; } } } elseif ($_POST['frmChangeAction']) { $varCouponID = $_POST['frmCouponID']; if ($_POST['frmChangeAction'] == 'Delete') { $objCoupon->removeCouponInformation($varCouponID); } elseif ($_POST['frmChangeAction'] == 'Inactive' || $_POST['frmChangeAction'] == 'Active') { $objCoupon->setCouponStatus($varCouponID, $_POST['frmChangeAction']); } if ($_POST['frmChangeAction'] == 'Active') { $objCore->setSuccessMsg(ADMIN_ACTIVATE_COUPON_SUCC_MSG); } else { $objCore->setSuccessMsg(ADMIN_DEACTIVATE_COUPON_SUCC_MSG); } header('location:' . $_SESSION['sessLastCouponPage']); } ?>