Display pages as per the role

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
2/4/2013 7:54:35 AM
Gravatar
Total Posts 5

Display pages as per the role

Hi All,

How integrate my user login details with mojoportal login.

 

Thanks,

Hari

2/4/2013 9:18:39 AM
Gravatar
Total Posts 18439

Re: Display pages as per the role

Internally mojoPortal uses its own user objects and user roles, you cannot change this. If you are authenticating against a different source then you need  a way to sync users into the mp_Users table or automatically create one if he does not exist at the time of successful authentication. This is what we do for ldap or windows authentication for example.

But user roles will be only from the roles added to the mojoPortal user and the role cookie will only reflect those roles.

The pages and menu items in mojoPortal are already filtered according the allowed page view roles and the user's roles. If a user is not in an allowed view role for a page he will not see the menu item for the page and will not be able to access the page by url.

Hope that helps,

Joe

2/4/2013 9:25:59 AM
Gravatar
Total Posts 5

Re: Display pages as per the role

Ok. I will add the users in the mojoPortal users table. But i need to use the custom login screen.

So how to create the cookies? Please explain the cookie names.

2/4/2013 9:33:54 AM
Gravatar
Total Posts 18439

Re: Display pages as per the role

In your custom login you are setting an authentication cookie right? If site settings has use email for login checked then your auth cookie should set the user email (corresponding to the email in mp_Users) as the cookie value, otherwise the auth cookie must correspond to the LoginName field in mp_Users).

If you do that correctly then it will find the site user and you should not have to worry about the role cookie, mojoPortal will set that cookie according to the user.

Hope that helps,

Joe

2/4/2013 10:01:00 AM
Gravatar
Total Posts 5

Re: Display pages as per the role

Sorry for the trouble.

I am very new to mojoPortal. I can't understand.

Please explain clearly

You must sign in to post in the forums. This thread is closed to new posts.