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;
In reply to Re^3: Parsing out URLs with regex (diedotstar)
by tye
in thread Parsing out URLs with regex
by xtomservox
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |