Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Checks whether a file or directory exists
<?php file_exists(string $filename): bool
<?php     protected function hasApplicableFontFile()

    {

        if (is_string($this->file)) {

            return file_exists($this->file);

        }



        return false;
<?php         $this->extension = array_key_exists('extension', $info) ? $info['extension'] : null;

        $this->filename = array_key_exists('filename', $info) ? $info['filename'] : null;



        if (file_exists($path) && is_file($path)) {

            $this->mime = finfo_file(finfo_open(FILEINFO_MIME_TYPE), $path);

        }
<?php     {

        $path = $this->basePath();



        if (file_exists($path) && is_file($path)) {

            return filesize($path);

        }

        
<?php     public function initFromPath($path)

    {

        if ( ! file_exists($path)) {

            throw new NotReadableException(

                "Unable to find file ({$path})."

            );
<?php                     foreach ($config->get('imagecache::paths') as $path) {


                        $image_path = $path.'/'.str_replace('..', '', $filename);

                        if (file_exists($image_path) && is_file($image_path)) {

                            break;

                        } else {

                            $image_path = false;