简体   繁体   English

导航和MVC网站导航的站点地图

[英]Sitemap for breadcrumb and navigation of an MVC site

I am creating an mvc 4 c# web application for an ecommerce site that has both products, categories but also traditional pages. 我正在为电子商务网站创建一个mvc 4 c#网络应用程序,该网站同时包含产品,类别和传统页面。

The site has a global and local navigation, and a breadcrumb. 该网站具有全球和本地导航以及面包屑。

To assist with managing the navigation, I am considering using a sitemap provider which can be populated and used to drive the navigation and breadcrumb. 为了帮助管理导航,我正在考虑使用可以填充并用于驱动导航和面包屑的站点地图提供程序。

Is there any easy way to do such, using a sitemap, custom populated to manager the navigation and breadcumb of the site. 有没有简单的方法可以做到这一点,使用站点地图,自定义填充来管理网站的导航和面包。 An awareness of where the user is on the site can be achieved from the url. 可以通过URL实现对用户在站点上的位置的了解。 Any examples from other solutions as how they achieve such? 其他解决方案如何实现这些示例?

Look at the nuget package mvc sitemap provider. 查看nuget包mvc网站地图提供程序。 It does that out the box. 开箱即用。 Tutorial here http://edspencer.me.uk/2011/02/10/mvc-sitemap-provider-tutorial/ 此处的教程http://edspencer.me.uk/2011/02/10/mvc-sitemap-provider-tutorial/

We use it for menus and breadcrumbs for all our MVC sites 我们将它用于所有MVC网站的菜单和面包屑

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM