Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

For a publishing site, I'm able to add Custom Actions to the site actions menu. Now I would like to hide all the default ones (except Edit Page). I tried to do this with the HideCustomAction Element but this doesn't seam to work.

In a publishing site I like to hide:

-New page ( * )
-New document Library
-new Site
-More Options

-Manage Content and Structure ( * )
-View all site content
-Edit in SharePoint Designer
-Site Permissions
-Site Settings

Removing them in the master page or using the security trimmed parameter is not realy an option since I could still see (*)

share|improve this question
add comment

3 Answers

r you interested using jquery? If you want to than just check below script in your console Is this work or not.

try this :

  $("[id*=SiteActionsMenu]").bind('click',function(){

   var i = 0;
   $('.ms-MenuUIPopupScreen').height('auto');
   $('.ms-MenuUIPopupInner').height('auto');
   $('.ms-MenuUIPopupInner').find('li').each(function(){
          if(i != 0)
            {
              $(this).hide();
            }
       i++;
   });

});
share|improve this answer
add comment

While it might be possible with JavaScript (and a sprinkle of jQuery if you like) you most likely end up like me writing a .NET WebControl to accomplish that task as using the HideCustomActionElement and masterpage tweaking methods do have some gotchas with SharePoint publishing features enabled.

To get started check out this thread Hide "New Site" on Site Actions menu?

share|improve this answer
add comment

Maybe you could accomplish it with the HideCustomActionElement with a custom Feature.

share|improve this answer
    
As mentioned I tried this but for some reason it doesn't work<br> <br><HideCustomAction<br> Id="HideCreatePublishingPage"<br>GroupId="SiteActions"<br> HideActionId="PublishingSiteActionsMenuCustomizer"<br> Location="Microsoft.SharePoint.StandardMenu"> </HideCustomAction> –  Wim Hill Aug 16 '11 at 12:11
    
Did you deploy this HideCustomAction with a feature scoped for Web and did you make sure the feature is activated? –  Matthias Aug 16 '11 at 12:32
    
I did even site scoped... And my custom actions that I add work fine –  Wim Hill Aug 16 '11 at 12:38
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.