Can anyone please provide some JavaScript code so I can display New but hide Upload and Actions in the menu of a document library.

  • Is it SharePoint 2013? – Unnie Sep 29 '15 at 15:20
  • 2
    What have you tried yourself sofar? StackOverflow is not a place where others do your job. – Danny '365CSI' Engelman Sep 29 '15 at 15:22

if you only want to hide some ribbon buttons, you can use a Content Editor web part in the library page, add some css to hide those button. some thing like this:

  display: none;

A more decent way is to deploy a SharePoint feature (Element.xml) to hide certain buttons. http://www.ktskumar.com/blog/2010/10/hide-button-from-sharepoint-ribbon/

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