One of the things I always struggle with are how to handle installations for web applications. I like using the web setup project template available in VS.NET, and for simple things I've had some success. But one thing that frustrated me was that during the installation process, it always asked the user to indicate the virtual directory I want to install to. That's great, but what if I want to install into the root folder of my website?
No problem, because all you need to do is remove the text in the textbox. You are allowed to have the virtual directory name to be blank, which will automatically put your installation in the root folder for the website. Here are few other facts:
- If you have multiple websites defined on your webserver, the install will not prompt you to select the website - it just selects one for you. If you stop all but the correct site, it will install into the running site, so I use this trick to get my installation into the correct website.
- If you like to define a different location for your website or virtual directory, I recommend that you create the site or virtual directory first, pointing it to the desired physical location. During installation, your files will then be located in the correct place.