According to other SO questions the problem has been solved by editing the hosts file and applicationhost file. These two files are already properly setup on my machine. This error started ocurrring right after I upgraded to visual studio 2015 SP1
http://bdtest.localhost:50119/ returns bad request
Hosts File -
application hosts file
<site name="BizDox.Web" id="2">
<application path="/" applicationPool="Clr4ClassicAppPool">
<virtualDirectory path="/" physicalPath="C:\Source\BizDox\Summer2015-Navigation\BizDox.Web" />
</application>
<bindings>
<binding protocol="http" bindingInformation="*:50119:*"/>
<binding protocol="http" bindingInformation="*:50119:localhost" />
<binding protocol="http" bindingInformation="*:50119:bdtest.localhost" />
<binding protocol="http" bindingInformation="*:50119:demo.localhost" />
<binding protocol="http" bindingInformation="*:50119:diy.localhost" />
<binding protocol="http" bindingInformation="*:50119:akuity.localhost" />
<binding protocol="http" bindingInformation="*:50119:owlsfactory.localhost" />
<binding protocol="http" bindingInformation="*:50119:rtp.localhost" />
<binding protocol="http" bindingInformation="*:50119:barebones.localhost" />
<binding protocol="http" bindingInformation="*:50119:sygnet.localhost" />
<binding protocol="http" bindingInformation="*:50119:firstsolution.localhost" />
</bindings>
</site>
I am running VS2015 as admin.
VS 2015 changes the default applicationhost.config file located in mydocuments/iisexpress to be a project specific applicationhost.config file. You can find this in your web project under a hidden .vs folder.
Your two options are to either open this folder and edit the applicatoinhost.config file or to tell the .proj file to use the default config file located in documents/iisexpress. You simply have to alter/add this line to the .proj file.
<UseGlobalApplicationHostFile>true</UseGlobalApplicationHostFile>
Add this to the top of the file inside the <PropertyGroup> tag
Make sure to close VS and re-open it for changes to take effect. Also make sure to run as administrator.
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