Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Register Tags Active Topics RSS Search Mark Forums Read SiteMap

Tags: , , , ,

Sponsored Links



Regex to verify email address

Software Development


Reply
 
Thread Tools Search this Thread
  #1  
Old 17-02-2010
Member
 
Join Date: Dec 2009
Posts: 213
Regex to verify email address

Hello,
I have a piece of code to verify that an email is fine but I just want to check syntax. I really struggling with regular expressions. They help me on this pattern has utilisers? If you know about this then please let me know or else an sample code will be great. Thanks in advance.
Reply With Quote
  #2  
Old 17-02-2010
Member
 
Join Date: Nov 2009
Posts: 520
Re: Regex to verify email address

Hello,
I'm not a professional in regular expressions, but no other details mail address should normally match the following pattern:
Code:
*@*.*
just try the above regular expression and see if the code works, and if it does not the post back with the error you get , because if you post back with the error , the errors can be easy for us to identify what exactly is the wrong in the code and where.
Reply With Quote
  #3  
Old 17-02-2010
Member
 
Join Date: Nov 2009
Posts: 344
Re: Regex to verify email address

Hello,
Here's my version, to think about, this is what I use for the doing the same. And i think this will be helpful to you. just have a look at it.
Code:
[a-zA-Z][\-_a-zA-Z0-9]*(.[a-zA-Z][\-_a-zA-Z0-9]*)*@[a-zA-Z][\-_a-zA-Z0-9]*(.[a-zA-Z][\-_a
If you have any more queries then post back and we will try to solve your problem.
Reply With Quote
  #4  
Old 17-02-2010
Member
 
Join Date: Dec 2009
Posts: 213
Re: Regex to verify email address

Hey,
Thank you, I laid this too (for url):
Code:
http:/ / [a-zA-Z ]*.[. \ -_/a-zA-Z] *. [a-zA-Z] (2,3)
But sometimes the url begins with https: / / I do not know how to put the s in options. Otherwise, the rest is it fair? Thanks for the kind of information and showing the present on the site.
Reply With Quote
  #5  
Old 17-02-2010
Member
 
Join Date: Nov 2009
Posts: 347
Re: Regex to verify email address

Hello,
For the s you can add one after the http [s]? The? representing the operator "than a". If your URL for you lack of taking into account a lot of things (numbers, some special characters - those who replace the spaces by example and probably others I forget). I hope you are understanding what i am trying to say here. If you have any queries then do post back.
Reply With Quote
  #6  
Old 17-02-2010
Member
 
Join Date: Dec 2009
Posts: 213
Re: Regex to verify email address

Hello,
Thank you for the "s". I wish we could return a url that includes only the domain name (http://ssDomaine.test.com) Then certain character who can not be used in the domain. But for now the code is working perfectly as I wished and I have no need of further code in this are. If i have any more difficulties then i will post back. Again, thanks for the help.
Reply With Quote
Reply

  TechArena Community > Software > Software Development


Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "Regex to verify email address"
Thread Thread Starter Forum Replies Last Post
Verify password and regex Gunner 1 Software Development 5 17-02-2010 05:44 AM
Regex to find email address TechGate Software Development 5 05-02-2010 01:55 AM
Cant Verify email address because I deleted email Michael Windows XP Support 6 18-11-2008 07:52 PM
Verify email address mssg in ver. 4.5? idahonet Windows XP Support 2 27-02-2008 06:53 AM
Verify email address CRK Windows XP Support 2 07-04-2007 09:09 AM


All times are GMT +5.5. The time now is 04:15 AM.