Re: regular expressions gods!
| From: | Justin French | Date: | Wed, 23 Aug 2000 06:17:33 +0000 |
| Subject: | Re: regular expressions gods! | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-13091@lists.php.net to get a copy of this message | ||
"WILSON, Nick" wrote:
> You should be able to exclude / in the reg exp, ie
>
> for ($i=0; $i< $(your number of tags-1); $i++)
> eregi_replace("(href=\")([^\/]*\.php)", "href=\"text_\\2",
> $tags[$i]);
>
> This will ommit matching anything with a / between the " and .php
>
> If you're using ./filename.php3 though then this won't work ...
Thanks heaps Jeremy and Nick!!!
I'm gonna go test it out now :)
Justin