The win7web client cannot execute exec and wants to open a local program through the page, for example, open a local txt file.
Exec ('d: \ test.txt ');
Write the php file and execute it in cmd to open it. But the process of notepad.exe is displayed in the process.
Find a solution.
System: win7
Server: wampserver
User: Administrator
Server and program disk: drive C
Don't say anything about exec or anything. I use it on my own computer and don't have to worry about security issues. Thank you.
I checked some information and added the IUSR permission in cmd. However, my add button is grayed out. No ..
In the service, select the option wampapache that interacts with the desktop. It does not work either.
Php Security mode is disabled.
Reply to discussion (solution)
No solution!
Exec can only execute programs without user interaction
You can see the notepad.exe process, which indicates that it is indeed executed, but you cannot see the notepad.exe interface, because it runs in the background
Since you don't see the interface, you can't perform the operation (you don't even have a chance to exit)
Besides, php runs on the server. even if the page is displayed on the server, how do you operate it? Assume that your server is in the United States.
No solution!
Exec can only execute programs without user interaction
You can see the notepad.exe process, which indicates that it is indeed executed, but you cannot see the notepad.exe interface, because it runs in the background
Since you don't see the interface, you can't perform the operation (you don't even have a chance to exit)
Besides, php runs on the server. even if the page is displayed on the server, how do you operate it? Assume that your server is in the United States.
I said it was local. It is not unsolvable. My code is okay on the company computer. But not at home ..
You can run apache without the apache service. Then we can achieve the effect.