问题
What would be the equivalent, by command line, of the create button in the Home Directory tab in IIS 6.0 ? (Used to create an application on a directory).
Edit : I already know of iidvdir. Unfortunalety, it doesn't seem to work the way I want it to (or I dont use it properly). Let's say that I have a website called Website for witch the root directory is C:\Website. I want to create the application in C:\Website\Application. If i try
iisvdir /create Website Application c:\website\Application
I get the message The virtual directory already exists. What I am doing wrong ?
回答1:
Command-line Tools Included in IIS. In-particular %SystemRoot%\System32\IIsVdir.vbs
.
回答2:
iisvdir /create Website Application c:\website\Application
It will only works if the directory C:\Website\Application doesn't already exists. If the directory exists, you will get the The virtual directory already exists message.
回答3:
use IIsVDir.vbs (look in windows\system32\IIsVDir.vbs)
来源:https://stackoverflow.com/questions/1610880/how-to-create-an-application-in-iis-using-command-line