重新组织ASP.NET MVC文件夹结构 [英] Reorganizing an ASP.NET MVC folder structure
本文介绍了重新组织ASP.NET MVC文件夹结构的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在MVC站点中有几个部分和小节,我希望文件夹布局的结构与默认结构不同。例如,如果我有站点的5个主要部分,则我想有5个文件夹,然后在其中的每个模型视图控制器文件夹中。有没有人有任何建议我将如何实现这个想法?并且我是否必须在我的global.ascx文件中设置自定义路由?
I have several sections and subsections of my MVC site, which I would like to have the folder layout to be structured differently than the default structure. For example if I have 5 main sections of the site, I would like to have 5 folders and then the models views controllers folders within each of those. Does anyone have any recommendations how I would accomplish this maybe a different idea? And would I have to set up custom routing in my global.ascx file?
推荐答案
请考虑使用 MVC中的区域
http://msdn.microsoft.com/en-us/library/ee671793.aspx
这篇关于重新组织ASP.NET MVC文件夹结构的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文