In PHP, how is the concept of "local" interpreted when checking for file existence?

When checking for file existence in PHP, the concept of "local" typically refers to the file path being relative to the current working directory of the script. To ensure that the file path is interpreted correctly as local, it's important to use the correct relative path or specify the full path to the file.

// Check for file existence using a relative path
$filename = 'example.txt';
if (file_exists($filename)) {
    echo "File exists!";
} else {
    echo "File does not exist.";
}