PHP File searching

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
Regit
Forum Newbie
Posts: 11
Joined: Tue Oct 10, 2006 7:36 am
Location: Here, there, everywhere

PHP File searching

Post by Regit »

I am writting a small application and needing some help.

I will be given a number and i have to do two things first go to the appropriate file directory

example:

if the number is 3800951 then the directory for that would be "38900951 Trunk Grey" or "3800951 Trunk Blue" im not told or guaranteed the directory name to be the same, only the number but no other directory will have that number.

Once in that directory i need to find a file and return that to the screen of the user it is a pdf file and i have no problem returning pdf files, my problem is getting that file.

example:

if im returning the spec sheet the file name will be "blah blah blah - SPEC.pdf" or operational standard - "blah blah blah - OPT.pdf"
I am guaranteed that all spec sheets will have SPEC.pdf and all op's will have OPT.pdf at the end of the file name, and there will only be one of each in the directory.

I appreciate all help and comments.
User avatar
volka
DevNet Evangelist
Posts: 8391
Joined: Tue May 07, 2002 9:48 am
Location: Berlin, ger

Post by volka »

User avatar
Regit
Forum Newbie
Posts: 11
Joined: Tue Oct 10, 2006 7:36 am
Location: Here, there, everywhere

Post by Regit »

I figured it was a function I havent worked with yet, thanks for the help :) time to go get it working hehe
Post Reply