Well, if setup correctly, all the form variable will end up in the $_POST array as a string, so there's nothing special in checking that -- you're just checking strings. Hence you can use any of the string functions or the regular expression functions to check the input.
Diego