|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-04-01 14:21 UTC] iliaa@php.net
[2004-04-07 10:58 UTC] sniper@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 11:00:01 2025 UTC |
Description: ------------ I've been trying to call a Win NT executable from a PHP4 script and the result is very strange. The browser hangs, and not finish to show results. If I stop the navigation, nothing appens. The script execute an win app like that: <? //...more code here.. exec("c:\appdir\appname.exe"); //...more code here.. ?> The code after the execution is not show in the browser. The app executes normally, but after the execution the script maybe hangs the browser. PHP was installed like a ISAPI module, not CGI. All help appreciated. Reproduce code: --------------- <? $server_path = "c:\\sites\\mysite\\uploaded\\"; mt_srand((double)microtime()*1000000); $filename_doc = strval(mt_rand(1, intval(1000))) . ".doc"; move_uploaded_file($_FILES['userfile']['tmp_name'], $server_path . $filename_doc); $filename = strval(mt_rand(1, intval(1000))) . ".htm"; $arr = array(); $exe_app = $server_path . "ConvertDoc.exe"; $params = " /S " . $server_path . $filename_doc . " /F9 /T " . $server_path . $filename . " /C4 /M2 /L " . $server_path . "wordlog.log /V"; exec($exe_app . $params, $arr, $return_val);