Answers for "validate credit cards when using php"

PHP
0

php validate credit card expiration date

$expires =  date_format( \DateTime::createFromFormat('ym', $cc_expiration),"ym");

$now =  date_format(new \DateTime(),"ym");

if ($expires < $now) {
    return 'Expired!';
}
Posted by: Guest on October-18-2020

Code answers related to "validate credit cards when using php"

Browse Popular Code Answers by Language