I am using VBScript and not ASP, I hope that it is ok to post in this section of the forum.
I have created a webform which consists of fields such as Firstname, Surname and phonenumber. I have written three validation routines. These check that the fields are not blank, the first and surname fields contain letters only and that the phone number field contains only numbers.
When a user successfully enters data he/she receives a confirmation message however when the user enters e.g. letters in the phone numebr field he/she receives an error message.
I am having two main problems:
1. When the form is tested the appropriate validations checks are carried out successfully and the form, I think is being sent to the server. I say I think because when I check the database on the server, the details from the form are not present.
2. When an error is made on the web form e.g. letters are entered into the phonenumber field, the correct error messages appears, however the form data is posted to the server. I checked the database and it contains the data from the form.
If data has been correctly entere dinto the form I would like the data from the form to be posted to the server. When there are errors I do not want the form data to be posted to the server.
I am sorry for the length of the post. I haven't got a clue why the form is behaving like this.
Does any one have any suggesstions as to how this can be resolved please?.
There is also a Submit button on the form which sends the webform to the serve