Wednesday, 27 February 2008

SharePoint 2007: Show the Quick Launch in Custom Web Part Pages

Funnily, when you create a Web Part Page, the Quick Launch is not available. This has always annoyed me, because it changes the look and feel of the whole site. Looks like this can be easily fixed.

One Off Fix

  • Open the Page for editing in Sharepoint Designer
  • Remove the LeftNavBar Content Place holder from Master Page (ie. remove the content Place holder)
  • Save the Page. You can now find the Quick Launch in Web Part Page

Permanent Fix

If you have MOSS 2007 - All you have to do is to activate the "Office SharePoint Server Publishing" feature for your team site. Once you activate this feature, the team site will have some publising site features: a new "pages" library will be created, and all new created pages will be automatically stored in this library. In addition all pages will display the same "envelope" - including the missing quick launch on the left side of each page.

The only problem with this solution is that now every change you make requires publishing, and this is certainly NOT a natural part of team-site working flow.

Hack

This is the same as above fix in SharePoint Designer however the hack is on the file system and applies to all team sites created on your server. Also, if any upgrade changes these files, you'll have the "old" style again. And please backup before you change anything.

If you only have WSS installed - in this case you don't have the "Office SharePoint Server Publishing" feature installed. However, you can change the team site page templates, and have them display the quick launch.

  • Browse to the "C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\1033\STS\DOCTEMP\SMARTPGS" folder on the SharePoint server.This folder contains all templates that you see in the "New Web Part Page" wizard
  • Every page inherits the same team site's master page, and all of them override this master page's placeholder tags. This is why the quick launch is not displayed in new pages created in a team site.
  • Delete the "PlaceHolderLeftNavBar" content tag in the required templates and save the file/s

References:

http://techblog.udayakumar.net/2007/08/how-to-display-quick-launch-in-web-part.html

http://kwizcom.blogspot.com/2007/05/adding-quick-launch-to-team-site-pages.html