reg-ex again

From: Date: Mon, 29 Apr 2002 07:22:42 +0000
Subject: reg-ex again
Groups: php.general 
Request: Send a blank email to php-general+get-95107@lists.php.net to get a copy of this message
I'm trying to find files in my array for example ="lg_imode.gif" and ="/db/imodeklein/edgar-IMODE-1-.gif" I want to differentiate between the files with slash at the front and ones without so that I can add a server path ! but as usual I' m having problems with the correct regex At the moment I've got this to find files with forward slash eregi_replace("([^\"]+[/+]+[a-z_/-]+[gif]+[/$])" and it seems to work.(although I think it's wrong) And I'm trying this to find the files without the slash at the front eregi_replace("([^\"]+(a-z_)+[gif]$)" which is definately not working. ....help ! thanks !

« previous php.general (#95107) next »