php shell example Example: php shell script <?php $output = shell_exec('cat /etc/hosts'); echo "<pre>$output</pre>"; ?>