Validating email using javascript

a CGI/Perl script on a Web server) sending a request to an Internet Mail Server, to check if the email address exists and if a connection would be accepted by the Mail Server.Last month I wrote about regular expressions in Java, today I’ll show you how to use regular expression in Java Script to validate email address.This post will describe the javascript email validation. Similarly, [a-cx-z] will match ‘a’ or ‘b’ or ‘c’ or ‘x’ or ‘y’ or ‘z’. As shown above, .(dot) matches a single occurrence of any character. Email Id needs to start with alphabets or numbers – regex will be ^([a-z A-Z0-9]) i.e.First and foremost, all apologies for such a long delay in writing a new post. But from now on I’ll try my best to be regular We will be using regular expression for email validation. I’ll see to it that by the time you finish reading this post, you would have got a fair idea about Regular Expressions. [ ] Brackets match a single character that is contained in the given expression. ^ Matches the starting position within the given string. * Matches the preceding element zero or more times. Matches the occurrence of the previous symbol not less than n and not more than m times. But what if we need to match an occurrence of (dot) itself. the email id should start with either an alphabet or a number. It can contain any number of alphabets, numbers and a few special characters. Then there should be the famous ‘@’ symbol which we simply write as @ 4.Having a-z and A-Z means that both lowercase and uppercase letters are allowed.

We can validate email address at client side and server side.

You can leave a comment, or trackback from your own site.

In most of the application there is a need to validate email address on the form.

Example Markup and script are provided for you to copy/paste into your HTML editor for inclusion on a web page.

If you are intending to include a 'Contact Us' page on your Website then you will need to create a more comprehensive FORM that communicates with a CGI program located on your site's Web server.