Hello all, I am new to php and need have created a php page that will collect information from a user then use that information to run a batch file. I am having troubles with the exec() command, it is not doing what I want it to do. I need to start a program on the computer not just the service. Here is an example.
When I use:
Run.php
<?
$command = "d:\test.bat";
exec($command);
?>
The batch file starts a vb script that starts a HyperTerminal session and then sends keys to the program. When I run the run.php script I see that HyperTerminal has started in the task manager but I need to have it started on the desktop. If I run the test.bat on the desktop everything works fine. I need hypertrm.exe to start on the screen to send oShell.SendKeys to the program
If I use the same script
<?
$command = "c:\windows\notepad.exe";
exec($command);
?>
I notice that notepad was started in the taskmanager put not on my screen. I was wondering what command I should use to get notepad to start on my computer when I go to I am using notepad as an example because if I can get that to work then I should get the hypertrm.exe to work.
Thanks
When I use:
Run.php
<?
$command = "d:\test.bat";
exec($command);
?>
The batch file starts a vb script that starts a HyperTerminal session and then sends keys to the program. When I run the run.php script I see that HyperTerminal has started in the task manager but I need to have it started on the desktop. If I run the test.bat on the desktop everything works fine. I need hypertrm.exe to start on the screen to send oShell.SendKeys to the program
If I use the same script
<?
$command = "c:\windows\notepad.exe";
exec($command);
?>
I notice that notepad was started in the taskmanager put not on my screen. I was wondering what command I should use to get notepad to start on my computer when I go to I am using notepad as an example because if I can get that to work then I should get the hypertrm.exe to work.
Thanks