mirror of
https://github.com/hotspotbilling/phpnuxbill.git
synced 2025-08-30 06:39:46 +02:00
fix: use where
instead of which
for windows host
This commit is contained in:
parent
d506dd66ff
commit
5072ff8ba2
1 changed files with 2 additions and 1 deletions
|
@ -146,7 +146,8 @@ switch ($action) {
|
||||||
$r = ORM::for_table('tbl_routers')->find_many();
|
$r = ORM::for_table('tbl_routers')->find_many();
|
||||||
$ui->assign('r', $r);
|
$ui->assign('r', $r);
|
||||||
if (function_exists("shell_exec")) {
|
if (function_exists("shell_exec")) {
|
||||||
$php = trim(shell_exec('which php'));
|
$which = stripos(php_uname('s'), "Win") === 0 ? 'where' : 'which';
|
||||||
|
$php = trim(shell_exec("$which php"));
|
||||||
if (empty($php)) {
|
if (empty($php)) {
|
||||||
$php = 'php';
|
$php = 'php';
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue