Jump to content

exec psexec


sanchez77

Recommended Posts

I'm using the PSTools psexec tool tp execute a script. But I can't figure out how to pass arguments to it.

 

I've tried

 

exec('C:\PSTools\psexec -d "C:\Program Files (x86)\PHP\php-cgi.exe" C:\inetpub\wwwroot\bkupdate.php "$var1" "$var2" ' );

 

exec('C:\PSTools\psexec -d "C:\Program Files (x86)\PHP\php-cgi.exe" C:\inetpub\wwwroot\bkupdate.php <$var1 $var2> ' );

 

and

 

exec('C:\PSTools\psexec -d "C:\Program Files (x86)\PHP\php-cgi.exe" C:\inetpub\wwwroot\bkupdate.php [$var1 $var2] ' );

 

Has anyone done something similar? Doe anyone know how to do that?

 

Thanks,

sanchez

Link to comment
https://forums.phpfreaks.com/topic/263550-exec-psexec/
Share on other sites

  • 3 weeks later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.