Command: $command_string
"; //echo "Command Ouput:
"; //output will be returned from the runcmd function call //run the script $output = array(); if ($ret_code == "on"){ $rc = runcmd($command_string, 0, $output); //mode 0 if ($rc == 0){ foreach ($outp as $key => $val){ echo $val. ""; } } }else{ //$rc = runcmd($command_string,1, $outp); //streaming mode - DOES NOT WORK YET $rc = runcmd($command_string, 0, $output); //mode 0 if ($rc == 0){ foreach ($output as $line){ echo "$line