We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When year is 2019 this is failing adding 20 in front
private function cleanSsn($ssn) { $ssn = preg_replace("/[^0-9]/", "", $ssn); $split = substr($ssn, 0, 2); if ($split != 19 && $split > date('y')) { $ssn = '19' . $ssn; } if ($split != 20 && $split <= date('y')) { $ssn = '20' . $ssn; } return $ssn;
The text was updated successfully, but these errors were encountered:
Could be useful to add check if century numbers are already in place
function cleanSsn($ssn) { $ssn = preg_replace("/[^0-9]/", "", $ssn);
if(12 === strlen($ssn)) return $ssn;
Sorry, something went wrong.
No branches or pull requests
When year is 2019 this is failing adding 20 in front
The text was updated successfully, but these errors were encountered: