I created a program that creates web architecture on a local server, then loads the necessary browser to display html and php pages on localhost.
Calling os.system kills the python process, but does not kill other processes - for example, httpd.exe and mysqld.exe
A subprocess call kills the httpd.exe and mysqld.exe , but continues to run python code, and after the subprocess call the code fails.
How can I kill or hide all the necessary processes after python code execution?
Here is my code.
os.makedirs(dr + x + '/admin' + '/css') dobj = open(dr + x + '/admin' + '/css' + '/style.css', 'w') dobj.close() del dobj os.makedirs(dr + x + '/admin' + '/js') os.makedirs(dr + x + '/admin' + '/img')
user1416451
source share