CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
regular expressions.. ?

 



mike robb
Deleted

Oct 24, 2000, 4:09 PM

Post #1 of 1 (387 views)
regular expressions.. ? Can't Post

I was wondering if it is possible to match something bounded by word breaks that is not inside certain markers.

this [abc] is a sample [/abc] test to match the word a in some text.

where this would match "a" that is not inside the [abc] and [/abc] markers

the \b does not work on my version of perl - but the look ahead and look behind? do.


here is what i have so far (it is actually perl replacing $i with $x

$str =~ s/(?<=[\n\f\r ])\Q$i\E(?=[\n\f\r. ])/$x/ig;

TIA.

--Mike
( http://www.js-examples.com )

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives