|
-
Apr 30th, 2011, 08:12 AM
#1
Thread Starter
Frenzied Member
Regular Expression for email validation
Unfortunately regular expressions are something I know nothing about.
I am trying to validate an email address using javascript and this is what I am using:
var expression = /^[a-zA-Z0-9]+[a-zA-Z0-9_.-]+[a-zA-Z0-9_-]+@[a-zA-Z0-9]+[a-zA-Z0-9.-]+[a-zA-Z0-9]+.[a-z]{2,4}$/;
However this doesn't allow for someone to use a filter on a gmail address e.g.
[email protected]
Can anyone help me with finding an expression that will allow me to do this?
Thanks.
-
Apr 30th, 2011, 06:05 PM
#2
Re: Regular Expression for email validation
I have the same problem. Are you looking at it from a framework point of view (say asp.net)?
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
-
May 1st, 2011, 07:51 AM
#3
Thread Starter
Frenzied Member
Re: Regular Expression for email validation
I'm not quite sure what you mean but I am using this for a client side validation of an email address on a web page using javascript. The server side validation will be the same but using php.
-
May 2nd, 2011, 07:04 AM
#4
Re: Regular Expression for email validation
I found this in the VB.NET codebank.
when you quote a post could you please do it via the "Reply With Quote" button or if it multiple post click the "''+" button then "Reply With Quote" button.
If this thread is finished with please mark it "Resolved" by selecting "Mark thread resolved" from the "Thread tools" drop-down menu.
https://get.cryptobrowser.site/30/4111672
-
May 2nd, 2011, 07:08 AM
#5
Thread Starter
Frenzied Member
Re: Regular Expression for email validation
As I said before, I am no expert, however it seems to me that that one still does not allow a plus, and unless I am mistaken it also only allows the address to have 2 sub domains?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|