HTTP Request Checker validating user inputs in PHP