Menu Home

stream_isatty

osbo.com | PHP | Functions | stream_isatty

Check if a stream is a TTY

Syntax

stream_isatty ( resource $stream ) : bool

Parameters

stream

The stream resource

Return

Returns TRUE on success or FALSE on failure.

Examples

<?

$filename = "stream_isatty.txt";
$mode = "r";

$handle = fopen($filename, $mode);

    $return = stream_isatty($handle);

    var_export($return);

fclose($handle);

?>
false

PHP