php exec is not executing the command

0 votes

I have tried to use exec() with 'whoami' to check if it works and I got the result of

nt authority\system

Now I need to run a .exe file with parameters from PHP via the exec() function. 

When I run this command from the PHP file:

exec('..\..\some_file.exe folder="C:\path_to_folder" param=1.xml report=2.xml');

Even exec('notepad.exe'); is not working. Does something have to be done with PHP configurations maybe?

Jul 24, 2022 in PHP by Kithuzzz
• 38,000 points
1,380 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In PHP

0 votes
0 answers

PHP is not recognized as an internal or external command in command prompt

I am getting this error when I ...READ MORE

May 7, 2022 in PHP by narikkadan
• 63,600 points
2,088 views
0 votes
0 answers

Php artisan make:auth command is not defined

I ran this command in Laravel 5.2 but ...READ MORE

Jul 21, 2022 in PHP by narikkadan
• 63,600 points
1,465 views
0 votes
1 answer

What is meant by passing the variable by value and reference in PHP?

Hello, When the variable is passed as value ...READ MORE

answered Mar 27, 2020 in PHP by Niroj
• 82,840 points
3,284 views
0 votes
1 answer

What is the use of $_REQUEST variable in php?

Hii @kartik, The $_REQUEST variable is used to read the ...READ MORE

answered Mar 27, 2020 in PHP by Niroj
• 82,840 points
3,323 views
0 votes
1 answer

How to check if php session is already started or not?

Hello kartik, Use session_id(), it returns an empty string ...READ MORE

answered Apr 1, 2020 in PHP by Niroj
• 82,840 points
5,747 views
0 votes
1 answer

'composer' is not recognized as an internal or external command in windows server

For anyone coming here from Google who ...READ MORE

answered Feb 17, 2022 in Others by Aditya
• 7,680 points
20,538 views
0 votes
0 answers

Find PHP version on windows command line

I wanted to know the version of ...READ MORE

Jun 14, 2022 in PHP by narikkadan
• 63,600 points
946 views
0 votes
0 answers

Need XAMPP with PHP 5.4 version - windows

Can someone please share with me any ...READ MORE

Jun 21, 2022 in PHP by narikkadan
• 63,600 points
1,011 views
0 votes
0 answers

Create PDF file using PHP

I want to create a PDF file ...READ MORE

Jun 24, 2022 in PHP by narikkadan
• 63,600 points
431 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP