PHP code example of johnpbloch / php_shell

1. Go to this page and download the library: Download johnpbloch/php_shell library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

johnpbloch / php_shell example snippets


use PHP_Shell\Bash;
// Using use:
echo Bash::exec('ls -la %s', escapeshellarg('.'));
// Using the fully qualified name:
echo \PHP_Shell\Sh::exec('git status');

pear channel-discover johnpbloch.github.com/pear
pear install johnpbloch/PHP_Shell