guarda la funzione file_exists():
http://it2.php.net/manual/en/function.file-exists.php

ciao