CLI

Check PHP is running:

 

php -v

 

Run PHP commands straight from the CLI:

 

php -r php-command

 

Run a PHP script:

 

php filename.php -r

 

PHP script, saved as file-name.php

 

#! /bin/php/

<?php

	phpinfo();

?>

Leave a Reply