url rewrite with visual studio 2012

2019-06-20 22:17发布

I'm trying to use the url rewrite module with an MVC application on VS 2012. I've installed the module using web platform 4.0, followed Ruslan's blog post, updated his js script according to the comments (specifically the last one by Brant Burnett on Oct 19th, and the script executed successfully. I checked the DotNetConfig.xsd and everything looks fine.

If I open IIS management console I see the Url Rewrite module and everything looks ok.

I create an simple MVC solution (with the default home/account controller), and when I add the simplest ToLowerCase rule (also copied from Ruslan's blog), I get the blue squiggly line under the tag and an http 500.19 if I try to execute. rebooting, etc. does not help. also important to mention I use IIS express 7.5.

the same procedure worked for me fine on a machine running VS 2010, url rewriting worked without a problem.

anyone knows what could go wrong? what info is needed for further analysis? why isn't intellisense working and the rewrite module recognized?

1条回答
该账号已被封号
2楼-- · 2019-06-20 23:02

The problem lies in version of .NET Framework, each version has its own config intellisense file. Additional hassle is that the file for 4.5 isn't in C:\Program Files (x86)\Microsoft Visual Studio 11.0\Xml\Schemas\, as DotNetConfig45.xsd, but in additional folder 1033.

Here I updated RuslanY's setup script for VS 2012 and .NET 3.5, 4.0 and 4.5: http://pastebin.com/8GGGHTBL

查看更多
登录 后发表回答