Regex Help
| From: | Sheridan Saint-Michel | Date: | Fri, 13 Jul 2001 16:03:41 +0000 |
| Subject: | Regex Help | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-57744@lists.php.net to get a copy of this message | ||
I am trying to write a script that needs a list of all the images in an HTML file.
I am trying this code
if (eregi ("(<img.+src=)(.+)[\s>]",$buffer, $regs ))
{
echo "$regs[2]<BR><BR>";
}
The problem, however is that when it looks at
<IMG SRC=images/Logo.gif ALT="Only Child Club - The Place for Only Children">
instead of getting images/Logo.gif like I want I am getting
images/Logo.gif ALT="Only Child Club - The Place for Only Children"
I am not as familiar with Regexes as I would like and any help would be greatly appreciated
Thanks
Sheridan Saint-Michel
Website Administrator
FoxJet, an ITW Company
www.foxjet.com