Originally posted by sidney
yep but no var dump thats just to show what output is in example
if (checkdate($check[0], $check[1], $check[2])){
echo "good";
} else {
echo "bad";
}
One last question, i think:
Is this the proper way for the explode? I dont know if there should be two //'s or just one.
And another one is, the checkdate looks for years starting with 1, so Im thinking i have to do a check to see if $check[2] is between 1904 and 2004, something like this:
if (checkdate($check[0], $check[1], $check[2])) {
$yearnow = date("Y");
$xx = $yearnow - 100;
while ($xx != $yearnow) {
if ($check[2] == $xx) {
echo "good";
exit;
} else {
echo "bad";
exit;
}
}
} else {
echo "bad";
exit;
}
Do you think thats an approraite way to do that?