Home > Backend Development > PHP Tutorial > 正则表达式字符串取反 如何弄

正则表达式字符串取反 如何弄

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 12:35:33
Original
2822 people have browsed it

正则表达式字符串取反 怎么弄?
我有一个url规则如下:

mm.[*|a|b|add].cn

其中 a , b , add 表示例外

例如

 mm.a.cn 无法匹配

 mm.x.cn 可以匹配

如何写正则???

我只知道 mm\.[a|b|add]\.cn 可以匹配所有的例外,但是我就是想要一个取反的结果?

正则表达式 正则 url
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template