The only function that already exists is checkdate(), but as we discussed earlier, if would be stupid to do that because you'd have to make a date first.
You could make your own function!!!
"Here's one I made earlier":
if ( ! check_hour( $_GET['hour'] ) )
{
print "That's not a valid hour!\n";
}
function check_hour ( $hour )
{
if ( ( $hour < 0 ) || ( $hour > 24 ) )
{
return false;
}
return true;
}
Another alternative might be for you to have a dropdown box on your page...instead of having them type the hour, have them select it from a list. Then there should be no problem...