Skip to main content
updated what the content being trimmed is
Source Link

I'm currently building a master page for a SharePoint 2010 site using Designer 2010. The look and feel has been largely completed, however I'd like to hide a component from everybody except the admins of the site.

My SPSecurityTrimmedControl currently looks like this:

<SharePoint:SPSecurityTrimmedControl ID="SPSecurityTrimmedControl" runat="server" AuthenticationRestrictions="AuthenticatedUsersOnly" Permissions="FullMask" PermissionContext="RootSite">
    // ... codeHTML elements to hidebe componenthidden
</SharePoint:SPSecurityTrimmedControl>

However, as it stands now, it only shows the control for everybody except admins, which is not what I want. Does anybody know what the proper permissions are for this control to be hidden from users that are not admins?

Thanks.

EDIT Updated the question to clarify what I am hiding. It will hide HTML elements/JavaScript, as opposed to code (such as C#).

I'm currently building a master page for a SharePoint 2010 site using Designer 2010. The look and feel has been largely completed, however I'd like to hide a component from everybody except the admins of the site.

My SPSecurityTrimmedControl currently looks like this:

<SharePoint:SPSecurityTrimmedControl ID="SPSecurityTrimmedControl" runat="server" AuthenticationRestrictions="AuthenticatedUsersOnly" Permissions="FullMask" PermissionContext="RootSite">
    // ... code to hide component
</SharePoint:SPSecurityTrimmedControl>

However, as it stands now, it only shows the control for everybody except admins, which is not what I want. Does anybody know what the proper permissions are for this control to be hidden from users that are not admins?

Thanks.

I'm currently building a master page for a SharePoint 2010 site using Designer 2010. The look and feel has been largely completed, however I'd like to hide a component from everybody except the admins of the site.

My SPSecurityTrimmedControl currently looks like this:

<SharePoint:SPSecurityTrimmedControl ID="SPSecurityTrimmedControl" runat="server" AuthenticationRestrictions="AuthenticatedUsersOnly" Permissions="FullMask" PermissionContext="RootSite">
    // ... HTML elements to be hidden
</SharePoint:SPSecurityTrimmedControl>

However, as it stands now, it only shows the control for everybody except admins, which is not what I want. Does anybody know what the proper permissions are for this control to be hidden from users that are not admins?

Thanks.

EDIT Updated the question to clarify what I am hiding. It will hide HTML elements/JavaScript, as opposed to code (such as C#).

Source Link

What permissions should I use for my SPSecurityTrimmedControl to only give access to admins?

I'm currently building a master page for a SharePoint 2010 site using Designer 2010. The look and feel has been largely completed, however I'd like to hide a component from everybody except the admins of the site.

My SPSecurityTrimmedControl currently looks like this:

<SharePoint:SPSecurityTrimmedControl ID="SPSecurityTrimmedControl" runat="server" AuthenticationRestrictions="AuthenticatedUsersOnly" Permissions="FullMask" PermissionContext="RootSite">
    // ... code to hide component
</SharePoint:SPSecurityTrimmedControl>

However, as it stands now, it only shows the control for everybody except admins, which is not what I want. Does anybody know what the proper permissions are for this control to be hidden from users that are not admins?

Thanks.