Permissions problem on custom module

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.
7/2/2012 2:40:38 AM
Gravatar
Total Posts 21

Permissions problem on custom module

Hi,

I am having a slight permissions issue at the moment. I have two users set up currently, one is an administrator and the other is a content administrator. The admin has permission across the site to edit all parts of the site but the content admin has permission to edit everything apart from a custom module I created. The custom module simply contains a bit of custom html plus the standard html module and when I click 'edit' when logged in as an administrator it works fine but when i'm logged in as a content administrator I get the following permissions error:

 

Sorry, you are not allowed to view this content. If you have questions about your permissions, please contact a site administrator.
Either you are not currently logged in, or you do not have access to this page within the site. Please contact the site administrator to obtain access.

 

I have checked the permission settings on that module and they are the same as all the other modules but for some reason this one wont let me edit it as a content administrator.

 

When using a custom module do I need to set permissions somewhere else other than under the settings tab?

 

Thanks

Damian

7/2/2012 9:19:42 AM
Gravatar
Total Posts 18439

Re: Permissions problem on custom module

Hi Damian,

"The custom module simply contains a bit of custom html plus the standard html module"

That is not supported. None of the content features are designed to used inside other content features. The security model expects them to be hosted directly in the page. The security enforcement does checks to verify the the instance of the feature is contained in the page.

If you want to modify the Html Content feature you should clone it first into a completely separate feature.

Hope that helps,

Joe

7/2/2012 9:32:46 AM
Gravatar
Total Posts 21

Re: Permissions problem on custom module

Hi Joe,

The reason for putting the html module within the custom module was so I could replicate it across several pages therefore when updates were made to the html content it would replicate across all pages that contain the custom module rather than just the page you are updating. Is there any other way to achieve this so that the security features would work?

 

Thanks

Damian

7/2/2012 9:41:00 AM
Gravatar
Total Posts 18439

Re: Permissions problem on custom module

Hi Damian,

We do have several approaches to publishing the same content on multiple pages.

Global content is one solution.

ModuleWrapper is probably closer to what you are looking for and it works with the Html Content feature though it isn't the most recommended thing and it doesn't solve your need for a custom feature and permissions may not work as you would like when using ModuleWrapper.

If you need to extend the Html Content feature, cloning it is the only recommended way.

Best,

Joe

7/2/2012 9:47:03 AM
Gravatar
Total Posts 21

Re: Permissions problem on custom module

Thanks Joe, I came across the Global Content feature just before I read your reply blush I think this may well work for what I want to achieve.

 

I guess I jumped the gun thinking I needed to wrap it in a custom module wink

 

I must say i'm more impressed by mojoportal the more I use it, keep up the good work!

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