search and replace in html text

2005-10-28 Thread Matthias Leopold
hi i want to search for a pattern in html text and replace only those occurences that are not enclosed inside (html tag, not perl operator). i was thinking of something like $string =~ s/$pattern/test for or similar; else replace/ge; another way could be splitting $string into an array,

Re: search and replace in html text

2005-10-28 Thread Jeff 'japhy' Pinyan
On Oct 28, Matthias Leopold said: i want to search for a pattern in html text and replace only those occurences that are not enclosed inside (html tag, not perl operator). It's easiest to use a real HTML parser. Otherwise, you'll probably get false positives and what-not. $string =~