exec("cd /d c:\xampp\htdocs\youtube");
exec("python main.py > c:\xampp\htdocs\youtube\out.txt");
I have written code in php so that it takes a python program and executes and it saves the result in out.txt but it is not working I did the same thing from cmd it is working where am i going wrong
cddoesn't mean that nextexecwill be called from target directory.