in reply to Search for complex string, and if it doesn't exist...
A: to search the same file for when the string "secret.html" does _not_ exist, andJust change the 'if' to 'unless'.
B: to be able to search for a more complex string than "secret.html". Actually, it'll be 4 more complex strings, to be exact, examples of which are:That's just 4 exact strings. Searching for exact strings is trivial. But...
I don't really know how to tell Perl to ignore things like whitespaces and the ":\" in pathnames, etc.now we enter the realm of vagueness. You have to describe exactly what you mean. Descriptions of the form "things like" and "etc" isn't something we can use to help you write the regex. 90% of writing a regex is to be able to describe what you mean - and until you are able to do so, noone can help you write a regex, except by guessing.
Abigail
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Search for complex string, and if it doesn't exist...
by dkaplowitz (Novice) on Mar 25, 2004 at 18:28 UTC | |
by QM (Parson) on Mar 25, 2004 at 19:43 UTC |