ASP.NET MVC3 In IIS 7.5

后端 未结 9 1109
别跟我提以往
别跟我提以往 2020-12-31 11:47

Hi I want to publish an MVC 3 site in Windows Server 2008 R2 SP1. I installed MVC 3 and MVC 2. When I created an MVC 2 site, it worked fine but the MVC 3 site did not work.

9条回答
  •  醉酒成梦
    2020-12-31 11:55

    My actual problem was that I had mucked around with the _ViewStart.cshtml and _Layout.cshtml files. Specifically, I had changed the name of the _Layout.cshtml file to _PageLayout.cshtml and amended the references to it in _ViewStart.cshtml.

    That worked on VS2010 and on my home machine running Windows 7 32-bit, but it did not work on either my work machine running Windows 7 64-bit or my development server running Windows Server 2008 R2.

    The solution for me was to now try to change the name of _Layout.cshtml file.

提交回复
热议问题