Thanks after playing about with that I've got the following which does seem to work !
$imode_code[$i] = eregi_replace("(src=)(\")([a-z0-9_\/-]+\.gif)(\")", "\\1\\2$path/\\3\\2", $imode_code[$i]); Very very very slowly getting the hang of regexs ! What does your /i do at the end ??? Thanks > Try this: > > preg_match_all("/src=(\'[a-z0-9_\/-]+\.gif\')/i", $input, $MATCH); > print_r($MATCH); > > -- > Jason Wong -> Gremlins Associates -> www.gremlins.com.hk > Open Source Software Systems Integrators > * Web Design & Hosting * Internet & Intranet Applications Development * > > /* > Money is its own reward. > */ > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php