MVC3 内返回的经典 ASP 页面
是否可以直接返回经典 ASP 网页作为操作结果等?我刚刚继承了一堆经典 ASP 应用程序,这些应用程序仍在维护甚至扩展中。
我希望停止编写新的经典 ASP 代码,转向基于 MVC 的设置(因为这是该部门的发展方向)。因此,我正在寻找不需要我重写所有应用程序但允许我慢慢添加用 ASP.Net 编写的功能的选项。
理想情况下,我希望围绕控制器等组织功能,然后返回现有 ASP 页面作为操作的结果。我希望 URL 结构看起来与普通 MVC 站点相同。
有什么想法或建议吗?我知道还有其他关于此的帖子。还没有看到任何尝试通过 Action Result 等返回 ASP 页面。
谢谢
Graeme
Is it possible to directly return a Classic ASP web page as an Action Result etc? I have just inherited a stack of Classic ASP applications that are still being maintained and even extended.
I am looking to stop writing new Classic ASP code move to an MVC based setup (as that is the direction the department is going). Therefore I am looking for any options that don't require me to rewrite all the applications but allow me to slowly add features written in ASP.Net.
Ideally I would like to organise features around controllers etc and then return existing ASP pages as the result of Actions. I'd like the URL structure to look the same as a normal MVC site.
Any thoughts or advice? I know there are other posts on this. Haven't seen any that are trying to return ASP pages via Action Result etc.
Thanks
Graeme
不,你能做的最好的就是重定向。如果您要将一些遗留的经典 ASP 站点迁移到 ASP.NET MVC,您可以逐步进行。您可以通过引入控制器、模型和视图开始一页一页地替换页面。
iframe
还可以用作迁移过程中两种技术之间互操作的临时解决方案。No. The best you could do is redirect. If you are migrating some legacy classic ASP site to ASP.NET MVC you could do it progressively. You can start replacing pages one by one by introducing controllers, models and views.
iframes
could also be used as a temporary solution to interoperate between the two technologies during the migration.