Web Hosting Talk







View Full Version : Finding file problem


Powi
03-31-2005, 10:59 PM
I downloaded a PHP script to make thumbs. This script creates a cache file with a name such as:

phpThumb_cache_..%2Fcache%2F_photo.jpg

Now, i want to copy the file, but first check if it exists.

if (file_exists('phpThumb_cache_..%2Fcache%2F_photo.jpg')) {

}

While the file DOES exist (checked it using FTP), this code tells me i doen't.

I made some tests and found out that the % sign is causing the trouble, how can i solve the problem?

Thanks a lot.

Powi

likonar
04-01-2005, 04:35 AM
%2F - is a slash, and you must not use / in the filenames
Check your downloaded php script, may it is a bug in it.