in reply to Finding a string in a webpage

Alternative: use lynx -dump [url] and search through that with a regex. That way you don't run into messy issues of whether the text is part of a tag or not.

You can also, if you're doing a complexish search, employ HTML::Parser or one of its subclasses in such a routine.

Philosophy can be made out of anything. Or less -- Jerry A. Fodor