特定电子邮件域的正则表达式 [英] regular expression for specific email domain
本文介绍了特定电子邮件域的正则表达式的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在努力验证电子邮件ID字段。
我需要正常表达固定域,如下所示。 />
ex:xyz@cognizant.com
在这里,@ cognizant.com必须修复。它应该接受只包含特定域名的电子邮件ID
你可以发送普通的expr吗
提前谢谢
解决方案
推荐此链接
http://stackoverflow.com/questions/18025221/validating-email-address-regular-expression-with-fixed-domain [< a href =http://stackoverflow.com/questions/18025221/validating-email-address-regular-expression-with-fixed-domain\"target =_ blanktitle =New Window> ^ ]
试试这个:
^ [_ A-Za-z0-9-\\ +] +(\\ 。[_ A-ZA-Z0-9 - ] +)* @ cognizant.com
hi,
I am traying to validate email id field.
I need regular expression for fixed domain as following.
ex: xyz@cognizant.com
Here, @cognizant.com must be fixed. It should accept email ids which contains only that specific domain
can u plz send the regular expr for that
Thanks in advance
解决方案
Refer this link
http://stackoverflow.com/questions/18025221/validating-email-address-regular-expression-with-fixed-domain[^]
Try this:
^[_A-Za-z0-9-\\+]+(\\.[_A-Za-z0-9-]+)*@cognizant.com
这篇关于特定电子邮件域的正则表达式的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文