Show protected pages in Navigation

Posted by Community Admin on 04-Aug-2018 15:59

Show protected pages in Navigation

All Replies

Posted by Community Admin on 17-Jul-2011 00:00

Hi,

After upgrade to Sitefinity version 4.1 SP2 my website is showing the menu navigation based on page accessibility and logged in user roles. I want to show all the pages links in navigation irrespective of the accessibility and user roles. In case of user don't have access on particular page he will click on link and redirected to No Access page where we are providing facility to user send mail  to admin for asking to access on page.

Showing all the navigation items in menu is very important for our website otherwise user will not be able to send the access request to admin.

I have created user control for my Left Side navigation where I am using SiteMapDataSource and  SiteMapBase.GetCurrentProvider().

Please help me how can I show all the menu items irrespective of accessibility and role.

Jesse Sanchez
IT Manager, CASAS
800-255-1036 ext.107

Posted by Community Admin on 18-Jul-2011 00:00

Hi Jess,

I'm sorry to that the new security implementations have messed up with the functionality you have set up. One option although not very flexible is to create a custom navigation where you hardcode the links to these pages, so they will always get displayed. Another one is to grant permissions for everyone, but deny some specific content permission on that page and have a check in your control whether this particular content is present on the page or not - if not - redirect to your custom page.

Best wishes,
Boyan Barnev
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 18-Jul-2011 00:00

Hello Jess,

Just a quick follow-up, another approach you might take is to set a custom selection of pages for your navigation control and add the links to your pages as external pages (use app relative paths e.g. ~/mypage) This way you can use the built in Navigation control and have the links appear always, irrelevant of the permissions you have set. Once clicked the link will redirect to the actual page where the page will either get displayed or return properly error code 403 which you can handle.

All the best,
Boyan Barnev
the Telerik team

Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

This thread is closed