Tags

, , ,

To set default tab is quite easy, just need to add a query string to the end of the URL with the InitialtabID function.

/AllItems.aspx?InitialTabId=Ribbon.Library

I had an interesting request recently, they want new form page to only display Brower tab and hide Edit tab.

image

so the new form url will be “/NewForm.aspx?InitialTabId=Ribbon.Read” and JS is

$(‘a.ms-cui-tt-a’).last().hide();

And I also found a good blog to manipulating the ribbon in 2010

http://doseofdotnet.wordpress.com/2011/09/09/manipulating-the-ribbon-in-sharepoint-2010-with-javascript-part-1/

Advertisements