jablonka.czprosek.czf

websvn

Subversion Repositories:
[/] [include/] [command.php] - Diff between revs 1 and 3

Show entire file Ignore whitespace

Rev 1 Rev 3
Line 91... Line 91...
if ($config->serverIsWindows) { if ($config->serverIsWindows) {
$cmd = "\"$cmd\""; $cmd = "\"$cmd\"";
} }
   
return $cmd; return $cmd;
  }
   
  // }}}
   
  // {{{ execCommand
   
  function execCommand($cmd, &$retcode) {
  global $config;
   
  // On Windows machines, the whole line needs quotes round it so that it's
  // passed to cmd.exe correctly
  // Since php 5.3.0 the quoting seems to be done internally
   
  if ($config->serverIsWindows && version_compare(PHP_VERSION, '5.3.0alpha') === -1) {
  $cmd = "\"$cmd\"";
  }
   
  return @exec($cmd, $tmp, $retcode);
  }
   
  // }}}
   
  // {{{ popenCommand
   
  function popenCommand($cmd, $mode) {
  global $config;
   
  // On Windows machines, the whole line needs quotes round it so that it's
  // passed to cmd.exe correctly
  // Since php 5.3.0 the quoting seems to be done internally
   
  if ($config->serverIsWindows && version_compare(PHP_VERSION, '5.3.0alpha') === -1) {
  $cmd = "\"$cmd\"";
  }
   
  return popen($cmd, $mode);
  }
   
  // }}}
   
  // {{{ passthruCommand
   
  function passthruCommand($cmd) {
  global $config;
   
  // On Windows machines, the whole line needs quotes round it so that it's
  // passed to cmd.exe correctly
  // Since php 5.3.0 the quoting seems to be done internally
   
  if ($config->serverIsWindows && version_compare(PHP_VERSION, '5.3.0alpha') === -1) {
  $cmd = "\"$cmd\"";
  }
   
  return passthru($cmd);
} }
   
// }}} // }}}
   
// {{{ runCommand // {{{ runCommand

Powered by WebSVN 2.2.1