Searching File Name For String With PHP
Posted: Sat Oct 25, 2008 5:41 pm
Hey guys.
I have some files on my web server and I need to search through their files name with a certain string. That string will change based upon the record that the loop is on (using a foreach loop to run through my array).
Right now, the files are named like such -- ESC-440_Paper_Bassalee.
Therotically, if I could get all of the file names in that specific folder to be converted to string names, that would be ideally. Then I could just explode the strings with the "_" delimiter and then search the arrays for the relationship.
Anyone have ANY idea how to handle this?
Thanks.
I have some files on my web server and I need to search through their files name with a certain string. That string will change based upon the record that the loop is on (using a foreach loop to run through my array).
Right now, the files are named like such -- ESC-440_Paper_Bassalee.
Therotically, if I could get all of the file names in that specific folder to be converted to string names, that would be ideally. Then I could just explode the strings with the "_" delimiter and then search the arrays for the relationship.
Anyone have ANY idea how to handle this?
Thanks.