in reply to Re: Re: Parsing out URLs with regex
in thread Parsing out URLs with regex
Actually, this is a good example of when .*? is not the best choice. [^"]* is a much better idea. You don't want to run into this problem:
where $1 will contain 'foo">...<a href="bar'. - tye$page= '<a href="foo">...' . '<a href="bar" title="baz"><b>Click Here'; $page =~ /<a href="(.*?)" title="(.*?)"><b>Click Here/i;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re^3: Parsing out URLs with regex (diedotstar)
by halley (Prior) on May 14, 2003 at 19:51 UTC | |
by tye (Sage) on May 14, 2003 at 19:56 UTC |