Hiding the SharePoint 2010 Ribbon Buttons via jQuery 3

Scott ZischerkHiding ribbon buttons across your entire site should be done in a feature and a custom actions file, but if you need to hide a button on a single page you can use the following:

This will hide the “Open With Explorer” button in the ribbon in SharePoint 2010.

http://code.jquery.com/jquery-latest.js

$(document).ready(function () 
{
    setTimeout(HideOpenWithExplorerRibbonButton, 10);  
});

function HideOpenWithExplorerRibbonButton()
{
    $('a[id*="OpenWithExplorer"]').hide();        
    setTimeout(HideOpenWithExplorerRibbonButton, 10);
}    

3 comments

  1. I used this code to try to hide the ApproveReject button on the ribbon with no success! Any ideas? I have tried a lot, do not want to use code. Trying to use something like this idea if only it would work!

    Like

  2. It can be almost impossible to find well-qualified users on this matter however you look like you be aware of exactly what you’re covering!

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s