Thursday 5 September 2013

SharePoint – Dynamically Hide Left Navigation (Re-usable Approach)

Applies: SharePoint ; Project Server

So you have deployed SharePoint and want to customise the look & feel and provide your own navigation from the Intranet/Portal Home Page/PMO Site or Project Workspace. But, you just cant seem to get rid of the left navigation. 

image

The easiest way to do this is to hide this navigation on page load, dynamically. Below are the steps to take;

  1. First, download zipped files containing text files (SP2010 OR SP2013)  that have script to hide the navigation.
  2. Extract the required file and upload to Site Collection library. any discreet library location is fine.
  3. Right click on this file and copy shortcut.
  4. Navigate to page where you want to hide the left navigation and select Page > Edit 
  5. Insert Content Editor Webpart (under the Media Category of Webparts). See figure below.
  6. Edit this Webpart and insert the Shortcut copied during step (3) above.
  7. Set the Chrome State > Chrome Type to None
  8. Click Apply and OK for the webpart.
  9. Finally, click Save & Close on the Page Ribbon Tab

image

Note: to restore the left navigation, simply put the page in edit mode and delete the content editor webpart.

Hope this helps. Happy customisation and enjoy SharePoint…ing!!

No comments:

Post a Comment

Please include your email address with comments.