$_PHP_SELF; ?> " method="POST"> <b>Select the format you want to view the system uptime on</b><br> <input type="radio" name="name" value=" ">Normal format<br> <input type="radio" name="name" value="-s">MM:HH:SS format<br> <input type="radio" name="name" value="-p">Short Format<br> <input type="radio" name="name" value="find">Windows Format (Only on Windows Systems)<br> <br><input type="Submit" /><br> </form> </body> <?php require_once 'jsonRPCClient.php'; $myExample = new jsonRPCClient('http://127.0.0.1/dvws/vulnerabilities/cmdi/server.php'); // performs some basic operation try { echo 'This application is using <i>' . $myExample->giveMeSomeData('name') . ' to execute commands:</i><br />' . "\n"; $myExample->changeYourState('I am using this function from the network'); } catch (Exception $e) { echo nl2br($e->getMessage()) . '<br />' . "\n"; } if (isset($_POST["name"])) { echo '<br /><b>The current system uptime is</b><br />' . "\n"; try { echo $myExample->getsystemstatus($_POST["name"]); } catch (Exception $e) { echo nl2br($e->getMessage()); } }