Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > Displaying different pages to different roles. View modes: 
User avatar
Member
Member
idorko - 3/19/2013 11:34:33 AM
   
Displaying different pages to different roles.
Is it possible to display a different version of a page based on a user's role?

We would like to display a different homepage for our intranet site depending on which location role the user is in. I understand that I can show/hide webparts based on role, but doing that would create a pretty complex page...

User avatar
Kentico Legend
Kentico Legend
Brenden Kehren - 3/19/2013 2:44:29 PM
   
RE:Displaying different pages to different roles.
Test this out, create a few "home" pages for each department. Then on the root of your site (master page) go to Edit>Properties>Security tab and add role Everyone Allow read access. This will give everyone read access to everything on your site (no worries, we'll override it later).

Next in one of your department specific home pages in the Access box, select Yes to require authentication and click ok. Then in the Permissions box, add Not authenticated users role and deny full control. Then add the department specific role and allow read control. For any other department specific roles, add them to deny full control.

By setting the permissions at the top department specific home page, all the child pages will inherit the same permissions.

Lastly, in your webpart that displays the navigation, in the System Settings, select the Check Permissions box. What will happen is if you have someone from Marketing log in and there are lets say 5 different "Home" pages, it will only display the Marketing home page and none of the others will be accessible to this user.

The key to this is creating department specific nodes on your content tree so you can inherit permissions. Hope that helps.

User avatar
Member
Member
idorko - 3/20/2013 12:22:55 PM
   
RE:Displaying different pages to different roles.
Thanks, that worked almost perfectly.

The only issue I'm still having is displaying the proper page when a user hits the site root.

The system won't let me alias more than one document to "/", so I'm not really sure how to cause the right home page to be loaded when a user hits the site.

User avatar
Kentico Legend
Kentico Legend
Brenden Kehren - 3/20/2013 6:50:47 PM
   
RE:Displaying different pages to different roles.
You can set the default start URL per user. I'd suggest doing that based on a role.

User avatar
Kentico Support
Kentico Support
kentico_radekm - 3/22/2013 4:40:02 AM
   
RE:Displaying different pages to different roles.
Hello.

You can try what FroggEye suggested. You can find this property in the Site Manager / Administration / Users / edit / General. It is called "Starting alias path." Or, you can set the same in Users management section in the CMSDesk.

Best Regards,
Radek Macalik

User avatar
Kentico Support
Kentico Support
kentico_radekm - 3/23/2013 6:07:40 AM
   
RE:Displaying different pages to different roles.
Hello.

Another option you could consider is using the Content personalization as described in http://devnet.kentico.com/docs/devguide/cp_overview.htm.

Best Regards,
Radek Macalik