in reply to Regexp: Match anything except a certain word
$test =~ s/(<a\s(?:(?!target=)(?!>).)*)(?=>)/$1 target="_blank"/sgi;
Tested.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Regexp: Match anything except a certain word
by fraktalisman (Hermit) on Apr 21, 2006 at 17:19 UTC | |
by ikegami (Patriarch) on Apr 21, 2006 at 17:26 UTC |