I created this class to get an easy to use form field validation script. Use this class to validate your database inputs or mail forms. Of course there is much more to validate: postcodes, special strings, credit card number etc. In the first version is it (only) possible to validate simple text, numbers, (US)dates and e-mail addresses. Invalid form fields will be reported inside a detailed error message. If all form fields are valid you can use the boolean to submit your form.

MoosendMoosend, the All-in-One marketing platform your business deserves. Start free today »
CloudwaysCloudways The Ultimate Managed Cloud Hosting Platform. Start Your Free Trial » No Credit Card Required.

Try it by yourself: