php - Finding an image in a folder with subfolders which contains a post value -
i using jquery post value page should search folder , sub-folders see file exists.
the start of filename have "hav_" , product code...
hav_345gg.jpg
i need take posted value product code , search folders find match return location link ie:
http://www.mydomain.co.uk/folder/subfolder/hav_345gg.jpg
any great.
another option make use of phps glob
function returns array based on pattern match. seems used in case. need careful of files similar names partially matching though such as:
- hav_123
- hav_1234
Comments
Post a Comment