Codeigniter validating dates
You make it easy for them to compare what they entered to the error message.
If you develop using a PHP framework such as Cake PHP, there is a built in validation system that makes validating form data trivial.
To accomplish this, I use an array called $form_errors.
I key the array using the name of the form field that caused the error.
It also prevents a user from having to re-enter every field to correct their error and complete your form.
To accomplish this in my own code, I copy the values from the $_POST array to another array.
I also order my validation rules in order of priority.