maartenba / MvcSiteMapProvider

An ASP.NET MVC SiteMapProvider implementation for the ASP.NET MVC framework.
Microsoft Public License
537 stars 220 forks source link

Breadcrumbs are not displayed correctly after publishing on PRD #493

Closed joocker closed 4 years ago

joocker commented 4 years ago

Hi, I am using MvcSiteMapProvider in my MVC5 project. Everything works fine on localhost and on testing AP server, but after publishing onto production AP server, there is an issue how the breadcrumbs are displayed:

Localhost and testing environment look like; image

Production looks like: image

Have you seen this issue? Any advice is very appreciated. It is hard to debug this problem when on localhost everything is working just fine.

Thank you very much.

metalrose24 commented 4 years ago

I had this same issue. It looks like something to do with the build via nuget is broken and it isn't inserting the views for the HTML helpers into your project as it should.

I had to add the "DisplayTemplates" folder into Views/Shared myself.

You can get the contents of the folder out the repository (one of the sample apps).

After that it should work when deployed as well as locally.

joocker commented 4 years ago

I had this same issue. It looks like something to do with the build via nuget is broken and it isn't inserting the views for the HTML helpers into your project as it should.

I had to add the "DisplayTemplates" folder into Views/Shared myself.

You can get the contents of the folder out the repository (one of the sample apps).

After that it should work when deployed as well as locally.

Thanks a lot. You were right. The views were not published in the DisplayTemplates folder.