I have a website working fine on IIS express until I wanted to add a second one and have them both run off the same port number. Now I can't figure out how to get the path right. When I browse to the site after running iIS express it complains of a error:
Unrecognized configuration path 'MACHINE/WEBROOT/APPHOST/RISWEB'
and IIS Express returns error 500.19
Here is my config. When I set the path to be "/" it works, but when its something else it does not. I would like to browse to http:// c65273/risweb and have my website show up.
<site name="RISWEB" id="1834812154">
<application path="/risweb" applicationPool="ConnectPool">
<virtualDirectory path="/risweb" physicalPath="C:\c2010\risweb\RISWEB" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:80:c65273" />
</bindings>
</site>
This file is located in the %userprofile%\Documents\IISExpress\config folder or %userprofile%\My Documents\IISExpress\config folder, depending on your OS. When you run a site from a configuration file, you can specify which site to run.
Yes, IIS Express uses the same applicationhost. config and web. config files supported by IIS.
Configure IIS express on visual studio vs folder (Hidden) -> Config -> applicationhost.
I hit a similar problem and was able to resolve it by doing the following:
applicationhost.config
Project Properties
> Web
tab and then click Create Virtual Directory
to have VS recreate the configuration section.It then worked fine, the resulting configuration section will look something like this:
<site name="WebDemos-Site" id="5">
<application path="/" applicationPool="Clr4IntegratedAppPool">
<virtualDirectory path="/" physicalPath="C:\Users\rvesse\Documents\My Web Sites\WebDemos-Site" />
</application>
<application path="/demos">
<virtualDirectory path="/" physicalPath="C:\Users\rvesse\Documents\mercurial\dotnetrdf\Samples\WebDemos" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:64132:localhost" />
</bindings>
</site>
Note that VS generates an empty website for the root directory of the site
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With