Run shell commands in php

Written By smart| 30 June 2009| No Comment

You can run shell commands in php,for example if you want to display a uptime  in php
example :

<?php

$results = exec(‘uptime’); //you need enter the command in exec filed

echo $results;

?>

or

<?

php system (“uptime”);

?>

Related Posts with Thumbnails

Share With Others

Leave your response!




Comment moderation is enabled. Your comment may take some time to appear.