PHP 7.0.26 Released

Voting

Please answer this simple SPAM challenge: four plus four?
(Example: nine)

The Note You're Voting On

Kodeart
6 years ago
Check directly without calling functions:
<?php
if (PHP_SAPI === 'cli')
{
  
// ...
}
?>

You can define a constant to use it elsewhere
<?php
define
('ISCLI', PHP_SAPI === 'cli');
?>

<< Back to user notes page

To Top