Post a reply

Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)


Topic review


But that still does not make this WinSCP question.

But anyway, you pass variables to the argument as with any other string in PHP:

exec("c:\WINDOWS\system32\cmd.exe /c START C:\inetpub\.....\sync.bat $variable1 $variable2");

Because I am using windows cmd to execute WinSCP batch file

Re: Passing arguments from PHP

what does this have to do with WinSCP?

Passing arguments from PHP

I am using php to execute cmd which executes my batch file. Is there a way to pass my php variables to the batch file? Below is my php code which is working well:
exec('c:\WINDOWS\system32\cmd.exe /c START C:\inetpub\.....\sync.bat');