Navigating SharePointby Jeff Webb, author of Essential SharePoint
The first (or maybe the second) thing people ask me after they install SharePoint is how to change the standard navigation parts: the Quick Launch and Navigation bars. My advice is to wait. The navigation may not be exactly you want, but it's most of what you need. Mick Jagger sang something about that.
First, develop the content of your site, get your document libraries and lists in place, and organize your site structure--then you can work on navigation details. It's perfectly OK to create a draft of the site in SharePoint before you go live.
Second, I tell customers to use broad site structures rather than deep ones, because Search works only within site boundaries in Windows SharePoint Services. If you create lots of subsites, users may have to navigate to each site and repeat their search to find what they want. Remember: document libraries store content; subsites control access.
Finally, grab your iPod, queue some Stones (Rolling, Joss, or otherwise), and set to work on navigation. Let's start with the easiest and most obvious tools: the Links list and Quick Launch. You get both of those parts automatically when you create a new Team Site.
To add items to the Links list, click on "Add new link" at the bottom of the web part. SharePoint displays the new item form for the Links list. After you click on "Save and Close," the link appears in the Links web part.
The Links web part displays the default view of the Links list. You can create new views by adding columns to the list and grouping or filtering items, and then modify the List web part to display that new view.
For example, I added a Type column to the Links list that accepts four choices: Books, Internal, Microsoft, and Other Sites. I created a new view in Links that groups items using the Type column, and then I modified the Links web part on my Home page to use that view instead of the default. Figure 1 shows the resulting tree view.
Figure 1. Create a tree view to categorize links
The Quick Launch bar on the left side of the Home page isn't as easy to customize as the Links list. Microsoft calls the Quick Launch a static web part because you can't edit it directly from the browser. However, you can add or remove links by changing the general settings of a list or document library. To do that, go to the list or library, click on "Modify settings and columns" -> "Change general settings" and change the Navigation setting as shown in Figure 2.
Figure 2. Change list or library general settings to add or remove links on the Quick Launch bar
You probably already knew how to do that, but did you know that you can trick SharePoint into displaying links to other sites? To do that, create a dummy library that appears in Quick Launch, and then add a folder in Internet Information Service (IIS) that redirects from the path for that library to the external site address.
For example, I followed these steps to create a Quick Launch link on my site's home page to the subsite for this article:
- From the top-level site's Home page, choose Create -> Document Library and create a new library named
SPArticle. That sets the path created by SharePoint.
- Go to the
SPArticlelibrary and choose "Modify settings and columns" -> "Change general settings," and rename the site
Navigating SharePoint. That gives the path a friendly name to display in the Quick Launch bar.
- Log on to the SharePoint server using Remote Desktop or by physically going to the server.
- Create new folders in the root folder of your SharePoint site. I used this command on the command line: md c:\inetpub\wwwroot\SPArticle\Forms.
- Start the IIS Manager, right-click on the folder you just created, and choose Properties.
- Set the properties of the Forms folder as shown in Figure 3, and click on OK. That redirects requests for the dummy library to the http://usingsharepoint.com/Navigating SharePoint site, where I published the samples for this article.
Now, Navigating SharePoint appears in the Documents section of the Quick Launch bar on my Home page. If you click on it, you'll go to http://usingsharepoint.com/Navigating. If you want to change the title of the link or delete it, select Site Settings -> Modify Site Content -> Customize link, where link is the name of the library.
You can link from Quick Launch to any site, but if you want an ASP.NET site to exist under a SharePoint domain, you must exclude the path from SharePoint Administration. To do that:
- Open the SharePoint Central Administration site.
- Choose "Configure virtual server settings" -> sitename -> "Define managed paths," and then enter the path for the ASP.NET site in Path, select "Excluded path," and click on OK as shown in Figure 4.
Figure 4. Exclude the path from SharePoint if it is an ASP.NET application
That's the easiest way I know to integrate ASP.NET with SharePoint on a single server.
So far I've showed you how to do a lot right from within SharePoint. That's a good approach, because SharePoint manages links and content efficiently within a database. As long as the changes you make are through the browser, SharePoint avoids duplicating similar pages and content.
However, that approach limits how much you can change static web parts like the Quick Launch and Navigation bars. For instance, if you want to change the section title "Documents" to "Sites," you have to use FrontPage 2003. To do that:
- Start FrontPage (you must use version 2003 or later).
- Choose File -> Open Site and type in the address of the site; for example, http://usingsharepoint.com/Navigating. SharePoint opens the site for editing and displays the folders and pages in the site.
- Select Default.aspx and press Ctrl-C, followed by Ctrl-V to make a backup copy of the page in case you break something. This is important!
- Double-click on Default.aspx to open it, and click on Split at the bottom of the edit window to display the split design/code view.
- Select Documents in the design pane to locate the link in the code pane, and change the word to
Sites. Figure 5 shows how to make the change.
To change the Navigation bar:
- Right-click on the Navigation bar in the design pane and choose Link Bar Properties. FrontPage displays the properties dialog (Figure 6).
- Add, change, or delete links using the controls on the dialog.
Figure 6. Editing the Navigation bar
When you save your changes in FrontPage, the new page is saved directly to the SharePoint database. You should view your changes in the browser before you exit FrontPage--some of FrontPage's features, such as Optimize HTML and Recalculate Hyperlinks, can break web parts. That won't happen with the simple example I've shown here, but if it does on your site, you'll want to restore the Home page from the backup you made in Step 3. (You did do that, didn't you?)
After a page is edited in FrontPage, it is unghosted in SharePoint. That means a copy of the actual page is stored and the page is no longer generated dynamically from the site template. That concept can be a little difficult to grasp, but it is the main reason I told you to wait at the beginning of this article.
SharePoint is based on templates. All of the sites, lists, libraries, and pages are composed from templates stored on the server. Any change to those templates ripples through all of the server's sites automatically--except for pages that are unghosted; those stay the same. You can guess that future versions of SharePoint might change some of the templates, and that might give you a headache in the future if you've made a lot of little edits here and there. It's OK to edit SharePoint pages in FrontPage--just be aware of the risks, and remember: you get what you need.
For more things to consider before editing SharePoint sites with FrontPage, see the Microsoft Knowledge Base article 831612.
To view the sample site created in this article and to download it as a site template, go to http://usingsharepoint.com/Navigating.
To get help from the SharePoint community, visit the newsgroup news:microsoft.public.sharepoint.windowsservices.
In May 2005, O'Reilly Media, Inc., released Essential SharePoint.
Sample Chapter 1: Why Use SharePoint? (PDF) is available free online.
For more information, or to order the book, click here.
Jeff Webb is a SharePoint consultant and trainer who has written about computers and technology for 20 years. Among his published O'Reilly titles are Essential SharePoint, SharePoint Office Pocket Guide, Programming Excel with VBA and .NET, and Excel 2003 Programming: A Developer's Notebook. Jeff was an original member of Microsoft's Visual Basic team.
Return to the Windows DevCenter.