How can i catch those values and put in to separate error messages.
$coupon_code = $fw->xss()->safe($_REQUEST['coupon_code']);
$coupon_code = $fw->voucher()->getByCodeStatus($coupon_code);
console.log($coupon_code);
//return 2 means no value in the credit card //
if($coupon_code == 1) //
{
echo("false");
}else if($coupon_code == 2){
echo("false");
}else{
echo("true");
}