Saturday, July 4th, 2009

Tag Archives: validate

How to validate a telephone number

This snippet is useful if you need to validate a telephone number using an editable list with specific formats.

Read more

Check (validate) if the uploaded file is an image

This script checks if the uploaded file (via a form) is actually an image. You can choose between 2 validators: one that will check if the file is actually an image and the other one which checks the extension of the uploaded file.

Read more

Validating an image upload

This is a useful JavaScript function which validates an image upload by checking the extension of the file that should be uploaded. If the extension is jpg, jpeg, png or gif it will return true. Otherwise, it will return false.

Read more

A simple AJAX (JQuery) Contact Form with PHP Validation

The aim of this tutorial is to help you to create a simple (tableless) contact form using JQuery and AJAX. We will have a HTML page which will contain the form, a CSS file, a php page where the data will be sent and another file where the validation function(s) will be located.

Read more

Validate (input) password

This is a useful function if you need to validate a password (input). If you have a form and you need to check if the username, which is registering, entered a valid password (without illegal characters) then this would help you to do it. Only letters, numbers and underscores are accepted.

Read more

Validate (input) username

Here’s a function that validates a username. It can be used when you have a register form and the user should enter a valid username (that shouldn’t contain illegal characters).

Read more

Validate numeric string

Check if a string is numeric or not.

Read more

E-Mail Address Validator

This function checks if an email address is valid or not. For example it is very useful if you have to validate a html form where someone should enter a real email address.

Read more