Combine classic ASP.NET and ASP.NET MVC within one web application

夙愿已清 提交于 2019-12-03 03:01:26

Aha! It seems that this is very much possible. Here's a comprehensive article which describes what should be done.

An ASP.NET Webforms application can become ASP.NET MVC enabled by following some simple steps,its quite easy infact see this link if you want to go rest for mvc heres a article Rest for mvc by Phil Haack and Rest like nature of MVC heres a comparison Rest in asp net vs wcf

The whole goal of routing is to break the one-to-one association between URLs and files in the server’s file system. However, the routing system still does check the file system to see if an incoming URL happens to match a file or disk, and if so, routing ignores the request (bypassing any route entries that the URL might also match) so that the file will be served directly.

So, to answer on a part of your question "is this possible at all": Yes, because routing system will recognize the .asmx file on the file system and it will process it in classic asp.net web services manner.

For the second question I'm not sure because I haven't been doing anything complex with web service inside of the asp.net mvc application.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!