1

我正在尝试执行它在 xdotool 命令中使用的 sh 脚本,这是从 PHP 页面调用的。

正在执行 apache 的用户是“守护进程”。

上海代码

echo $1
win=`xdotool search --onlyvisible --name Zoiper windowactivate`
whoami
sleep 2
xdotool $win type $1
key Return
sleep 10
xdotool key alt+h

PHP 代码

<?php
    shell_exec("sudo sh /tmp/zoiper_dialer.sh " . $phone);
?>
4

0 回答 0