/ Published in: PHP
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
function checkDateFormat($date) { //match the format of the date { //check weather the date is valid of not return true; else return false; } else return false; } echo checkDateFormat("2008-02-29"); //return true echo checkDateFormat("2007-02-29"); //return false