伤心.....POSIX有没有同样的语法啊!
AccountDemander at gmx dot de
01-Dec-2003 02:10
It's always been a great problem to exclude whole strings. It's easy to exclude a single characters by [^jkhsd], but you cannot exclude whole strings that way... you think!Here's an easy way to exclude strings:
$s = "string to exclude";
preg_match("/[^" . $s . "]/", $string);
Hope this might help... .
AccountDemander at gmx dot de
01-Dec-2003 02:10
It's always been a great problem to exclude whole strings. It's easy to exclude a single characters by [^jkhsd], but you cannot exclude whole strings that way... you think!Here's an easy way to exclude strings:
$s = "string to exclude";
preg_match("/[^" . $s . "]/", $string);
Hope this might help... .
<a.*href=\"(.+)\".*>.*<\/a>
$link=$m["0"];
print_r($link);
再说了php在这两种不同的正则表达式中的函数库中就是PERL兼容的功能强