我想倒置一个正则表达式,我想匹配所有没有特殊电子邮件用户名的字符串。如:在正则表达式中,这是什么--->“?!”
my email is [email protected] and I love programming
my email is [email protected] and I love programming
my email is [email protected] and I love programming
my email is [email protected] and I love programming
全部不应该匹配。
如果我想匹配他们,我使用/[email protected]*[\.].*/
。一位朋友告诉我,如果我想反转它,我必须使用?!
,但我不知道如何?
请看这里:: http://stackoverflow.com/questions/10804732/what-is-the-difference-between-and-in-regex – 2013-04-04 06:03:19
你不需要反转正则表达式,你只需要反转匹配功能。例如。 'if(!str.match(/.../))'...... – deceze 2013-04-04 06:05:33
这不好。我想使用正则表达式本身 – Myriam 2013-04-04 06:09:33