F::show PHP Method

show() public static method

Read and send the file with the correct headers
public static show ( string $file )
$file string
    public static function show($file)
    {
        // stop the download if the file does not exist or is not readable
        if (!is_file($file) || !is_readable($file)) {
            return false;
        }
        // send the browser headers
        header::type(f::mime($file));
        // send the file
        die(f::read($file));
    }