vpganesh Posted January 30, 2008 Share Posted January 30, 2008 Hi I have a senario where i need to execute an external batch file and need to pass 2 values then it will give a output using i need to read the output and show it in the browser. step 1 : call command exe file. step 2 : enter user name step 3 : enter password step 4 : read the result and publish in the browser How can we do that using php? Please help urgent. Ganesh Quote Link to comment https://forums.phpfreaks.com/topic/88532-external-command-execution-with-result-tobe-published/ Share on other sites More sharing options...
pdkv2 Posted January 30, 2008 Share Posted January 30, 2008 <?php $arr_output=array(); $op= exec("dir c:" , $arr_output); print_r($arr_output); ?> OR <?php $arr_output=array(); $op= exec("ls -al" , $arr_output); print_r($arr_output); ?> Cheers ! Sharad. Quote Link to comment https://forums.phpfreaks.com/topic/88532-external-command-execution-with-result-tobe-published/#findComment-453221 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.