ereg() HELP!!!
| From: | Jesse Binam | Date: | Wed, 08 Nov 2000 01:00:17 +0000 |
| Subject: | ereg() HELP!!! | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-24229@lists.php.net to get a copy of this message | ||
Hey all,
I have been playing with this for going on 5 hours!! ARRRGGG!!!
I am making a script that takes HTML and makes a text and HTML version of
the page. I need to replace <img> tags with the src path.
For example <img src="http://www.domain.com/images/pic.jpg">
would be
replaced with <<http://www.domain.com/images/pic.jpg>>
But it has to be flexible enough to allow the user to put in width, height,
border, or whatever other parameters they want.
This is the code that I have
while(ereg("SOMETHING!!", $page, $match))
{
$text_message = eregi_replace($match[0], "<<$match[1]>>", $page);
}
Please someone spare me!!
Thanks,
Jess