問題があります。共有ホスティング環境で、wkhtmltopdf を呼び出して PDF ファイルを生成する PHP クラスを使用していました。サーバー攻撃により、ホストが proc_open と shell_Exec を無効にし、攻撃者が使用すると問題を引き起こす可能性のあるすべての関数が発生しました。ホストがこれらの機能を無効にする前に、すべてが正常に機能していました。私が使用する PHP クラスには、proc_open 関数が無効になっているために機能しない以下のメソッドがあります。正確な結果を返す以下のメソッドの代わりに使用できる代替手段はありますか? どんな助けでも大歓迎です。
private static function _pipeExec($cmd,$input=''){
$proc=proc_open($cmd,array(0=>array('pipe','r'),1=>array('pipe','w'),2=>array('pipe','w')),$pipes);
fwrite($pipes[0],$input);
fclose($pipes[0]);
$stdout=stream_get_contents($pipes[1]);
fclose($pipes[1]);
$stderr=stream_get_contents($pipes[2]);
fclose($pipes[2]);
$rtn=proc_close($proc);
return array(
'stdout'=>$stdout,
'stderr'=>$stderr,
'return'=>$rtn
);
}