Checking Whether a File Exists : file_exists « File Directory « PHP
- PHP
- File Directory
- file_exists
Checking Whether a File Exists
<?
if (file_exists("snapshot1.png")) {
print "Snapshot1.png exists!\n";
} else {
print "Snapshot1.png does not exist!\n";
}
?>
Related examples in the same category