I have IIS 5 and I want to make a simple page that lets me run two .CMD
(batch files) that I've placed in a cgi-bin type directory. Under the
virtual directory application settings, I select "Configuration", but what
do I put in "Application Mappings" to execute a .cmd file?
c:\winnt\system32\cmd.exe does not work btw.

Thanks,
Ketta

Re: Executing .CMD Files... by Ketta

Ketta
Sat Oct 11 18:41:57 CDT 2003

Well, cmd /c <command> does this, but it just returns cgi errors and does
not work... Is there some simple scripting language I can use to run this
trivial command from a web form?

"Ketta" <no@post.net> wrote in message
news:OzEzDlCkDHA.3612@TK2MSFTNGP11.phx.gbl...
> I have IIS 5 and I want to make a simple page that lets me run two .CMD
> (batch files) that I've placed in a cgi-bin type directory. Under the
> virtual directory application settings, I select "Configuration", but what
> do I put in "Application Mappings" to execute a .cmd file?
> c:\winnt\system32\cmd.exe does not work btw.
>
> Thanks,
> Ketta
>
>



Re: Executing .CMD Files... by David

David
Sat Oct 11 19:59:11 CDT 2003

There are two ways to execute .CMD files
1. As a script accessible via a URL on the server
2. Executed by some other script on the server and is not visible as a URL

#1. C:\winnt\system32\cmd.exe /c "%s" "%s"
#2. In ASP, use WshShell.Run( "Full-path-to-CMD-srcipt" );

If you're merely running these two .CMD as the resulting action of some
other Web page, I would suggest #2. #1 is a greater security risk since it
allows the eventual execution of ANY .CMD script on the server, not just the
two you want to run.

--
//David
IIS
This posting is provided "AS IS" with no warranties, and confers no rights.
//
"Ketta" <no@post.net> wrote in message
news:OzEzDlCkDHA.3612@TK2MSFTNGP11.phx.gbl...
I have IIS 5 and I want to make a simple page that lets me run two .CMD
(batch files) that I've placed in a cgi-bin type directory. Under the
virtual directory application settings, I select "Configuration", but what
do I put in "Application Mappings" to execute a .cmd file?
c:\winnt\system32\cmd.exe does not work btw.

Thanks,
Ketta