public function exec($command) { $output = null; exec('(' . escapeshellcmd($command) . ') 2>&1', $output); return $output; }