Chapter 3. The Anatomy of a SharePoint Page

WHAT YOU WILL LEARN IN THIS CHAPTER

  • The primary types of pages in SharePoint

  • How SharePoint assembles pages

  • How to edit a master page

  • Major content placeholders in a SharePoint Master Page

SharePoint 2010 comes in two flavors, SharePoint Foundation and SharePoint Server. This chapter covers the pages found in SharePoint Foundation. The goal of this chapter is to give you the conceptual and technical fundamentals required to customize your SharePoint site. The assumption is that you have a basic understanding of HTML, CSS, and web development concepts.

HOW SHAREPOINT PAGES WORK

A basic understanding of SharePoint site architecture will help you understand the nuts and bolts of SharePoint pages. The entry point to a SharePoint site is a web application, which is the highest level "container" for sites and has common services and features available to all sites within it. Within a web application is at least one site collection. A site collection is a group of sites that share properties for managing content and user permissions. The top-level or root site within a site collection is where you manage many administrative functions and store common files used in all sub sites.

Figure 3-1 illustrates the site hierarchy in SharePoint and highlights the libraries discussed in this chapter. SharePoint pages can be stored in any document library.

Figure 3-1

Figure 3.1. Figure 3-1

If you have a background in web design and development, you are familiar with physical web pages that you can edit directly using page editing software or Notepad. This type of site is fine for very small sites. Larger sites with more than a few pages are inefficient and cumbersome to maintain because of the redundant structural and behavioral instructions repeated in each page.

In contrast, SharePoint manages web content efficiently by storing content separately from structural and behavioral instructions. That way, only one physical copy of the page file is required.

The physical pages that live in the SharePoint file system serve as the master blueprint for any page inheriting from it. You should think of these as the "sacred originals that should never be touched." These "sacred originals," along with other information that helps define your site, form a master template called a site definition. This site definition lives on the hard disk of each file server (or web front end), and is used to build each actual SharePoint site that a user creates.

Most pages on a SharePoint site are assembled from a combination of these "sacred original" physical pages, and instance data for the page that lives in the content database. Content such as page content, HTML, and most scripts and styles live in this database and not on the file system.

Construction of the page takes place when the browser requests it. That means that when you look at a SharePoint page in your browser, a physical version of that web page does not exist. It blows your mind, doesn't it?

Figure 3-2 shows the process by which a page is assembled by a SharePoint server.

Figure 3-2

Figure 3.2. Figure 3-2

Note

For more details about how SharePoint is physically structured, see Appendix B.

PAGE TYPES

Two core types of pages are in SharePoint 2010: application pages and site pages. Understanding the differences between the two types of pages can save you a few headaches. This chapter focuses on site pages as used in SharePoint Foundation 2010. SharePoint Server 2010 also includes special site pages, called publishing pages, with extra features specifically for managing large amounts of web content. These will covered in detail in Chapter 4, but keep in mind that everything covered in this chapter also applies to publishing pages.

Application pages are more like traditional web pages, in that they are stored directly on the file system of the web front-end, and are complete in themselves. While they will reflect the styles you apply to your site (see Chapter 5), you do not otherwise have any ability to edit these pages through SharePoint Designer.

Site pages are pages that users edit, add web parts to, and can create and customize through the browser or with tools such as SharePoint Designer. Site pages are stored in the site collection's content database.

SharePoint Content Pages

Most SharePoint pages have the following key characteristics:

  • They are .ASPX (ASP.NET) form pages.

  • They use an ASP.NET master page that contains SharePoint-related placeholders that provide the majority of the page's look and feel.

  • One of these placeholders, PlaceHolderMain, contains the actual instance information for the page. Within that placeholder is the magic that makes each page type unique.

Web Part Pages

The Web Part Page is the primary page for presenting web parts, libraries, and lists. If you have a need for unstructured content such as text and images, you should plan to use a wiki page, which you will learn about later in this chapter.

Web part pages organize content through web part zones. A web part zone is a predefined area for adding web parts. You can create web part pages using the browser or with SharePoint Designer.

As you can see in Figure 3-3, web parts sit in web part zones that are part of a page template known in SharePoint as the master page. You will learn more about Master Pages in detail later in this chapter.

Figure 3-3

Figure 3.3. Figure 3-3

Users with appropriate permissions can create new pages and add, configure, or remove web parts through the web interface. You may ask why you would need to create a new Web Part Page in SharePoint Designer instead of the browser. With SharePoint Designer, you can do much more than you can through the browser. You can customize the content areas or create custom web parts called Data View Web Parts, which are covered in Chapter 8, "XSLT Data Views and Forms."

Wiki Pages

Wiki pages are a specialized version of the standard Web Part page and incorporate the wiki concept, which is collaborative and "living" because it continually changes through input from multiple users. Like Web Part pages, wiki pages have several pre-defined layouts, with different zone patterns. Unlike Web Part pages, these wiki content zones allow both rich text and web parts to be freely intermingled. Figure 3-4 illustrates the freeform layout of a wiki page. You can add web parts, images, and text directly to the rich content area or wiki field.

Figure 3-4

Figure 3.4. Figure 3-4

If you have worked with previous versions of SharePoint, you may be pleasantly surprised when you create your first collaboration site in SharePoint 2010. Instead of the boxy, data-driven presentation that was standard in team sites, you will be working with a new type of page, the Wiki Page. MOSS 2007 and WSS 3.0 had a separate site type called a wiki. SharePoint 2010 removes Wiki as a site type but incorporates much-enhanced wiki functionality directly in the standard team site template.

Seen below in Figure 3-5 is the Welcome Page, a wiki page used as the home page of a team site.

Because Microsoft understood that there was a need for unstructured collaboration, you can make the Welcome Page the home page of any site template in SharePoint. You can activate this feature in the Site Features section of the Site Settings page.

Although you can create additional Wiki libraries with any name, by default, SharePoint 2010 team sites create one called Site Pages. (Yes, it can easily be confused with the generic idea of "site pages" described earlier in the chapter. The builders of SharePoint have a penchant for using general terms to name specific objects....) You can find these site pages in SharePoint Designer under the Site Objects menu, as shown in Figure 3-6.

Figure 3-5

Figure 3.5. Figure 3-5

Figure 3-6

Figure 3.6. Figure 3-6

View Pages

In the root of each list and library is the Forms folder. In this folder is a collection of pages used for entering and displaying the information in that list. These pages are called view pages, yet they are also web part pages.

End users can create view pages through the web interface, but unlike the generic web part pages mentioned earlier, view pages are both edited and created in SharePoint Designer.

Figure 3-7 shows a list view page for a Shared Documents Library as seen in the browser.

Figure 3-7

Figure 3.7. Figure 3-7

View pages typically contain HTML controls to display or edit a list item. For more information about creating a view page, see Chapter 8, "XSLT Data Views and Forms."

A Note about Page Customization

By default, most SharePoint content pages, regardless of type, are based upon the "sacred original" site definition file plus instance information pulled from the content database. When you edit such a page in SharePoint Designer and save it, the link to its site definition file is broken. A copy of the site definition file is merged with its instance information and the result is then stored in the content database. Such a page is called a customized page.

Figure 3-8

Figure 3.8. Figure 3-8

When this happens, SharePoint gives you the warning shown in Figure 3-8 before breaking the link.

You can restore the link to the site definition file by right-clicking the page in SharePoint Designer and selecting "Reset to Site Definition" from the context menu. This will re-establish the link, but it will also leave any content you have added to web part or content zones within the page intact. Additionally, the customized file is renamed and stored in the same folder for backup reasons.

MASTER PAGES

Master pages are responsible for the consistent structural elements of a SharePoint page. The headings, navigation, footers, and logos that are consistent throughout many pages are contained in the master page.

Master pages provide a special type of control called a ContentPlaceHolder. Content placeholders are areas of replaceable content on the master page. In the code, they are book-ended by the following: <asp:ContentPlaceHolder>.

Although a master page may define many ContentPlaceHolder controls, a page does not have to implement a corresponding content control. You can think of these controls as little television screens: the content may change, but it is always delivered through the same little box.

The most common ContentPlaceHolder control is PlaceHolderMain, which displays the main body of the page. Other ContentPlaceHolder controls include PlaceHolderLeftNavBar, which contains the Quick Launch bar on the left side of the page, PlaceHolderTopNavBar, which contains the Top Navigation tabs at the top of the page, and PlaceHolderSearchArea, which contains the page's search controls. Depending on whether you are using SharePoint Foundation 2010 versus SharePoint Server 2010, your master pages may have many more additional ContentPlaceHolder controls.

When you create a new page in your site, the page will automatically inherit its basic layout and structure from the site's master page. Optionally, a page can contain one or more Content controls to specify the content to display in the corresponding ContentPlaceHolder controls provided by the master page. For instance, if you want to display the text "Hello, World!" in your page, you add the following code to your page:

<asp:Content ContentPlaceHolderId="PlaceHolderMain" runat="server">
    Hello, World!
</asp:Content>

When the page is requested from the server, the master page is loaded, which provides the ContentPlaceHolder controls for the page, and the page provides the Content controls to specify the content. In the previous code snippet, "Hello, World!" would appear in the main body of the page because the Content control's ContentPlaceHolderId attribute was set to PlaceHolderMain. The value of the ContentPlaceHolderId attribute must match the ID attribute of one of the master page's ContentPlaceHolder controls or the page will not load, leaving the user with a friendly, but uninformative error message.

Warning

Do not delete any ContentPlaceHolder controls from your master pages. You will get an error if a page that references a missing ContentPlaceHolder control is requested from the server. If you want to hide a single ContentPlaceHolder control, simply set its Visible attribute to False.

You can use Content controls for more than just content; you can use them to hide content as well. If you want to hide the search controls from a particular page in your site, add an empty Content control to the page and set its ContentPlaceHolderId attribute to PlaceHolderSearchArea. When the page loads, the "blank" content of the empty Content control replaces the default search controls that appear on the page.

Master Page Locations

Master pages are stored in a special Master Page Gallery library located within each site collection in the /_catalogs/masterpage directory. This library is accessible from the Site Collection Settings page as well as in SharePoint Designer, as shown in Figure 3-9.

Figure 3-9

Figure 3.9. Figure 3-9

Only one gallery exists per site collection and it is automatically populated when a new site collection is provisioned. Master pages cannot be shared across site collections, but a root site can share its master pages with the other sites in its site collection.

Default Master Pages

There are many master pages available in SharePoint Foundation Server. SharePoint provides a variety of master pages: v4.master, default.master, minimal.master, simple.master, and MWSDefaultv4.master. Another master page, nightandday.master is available in SharePoint Server 2010. It has slightly different content placeholders specializing in managing web content and is discussed in detail in Chapter 4.

v4.master

v4.master, shown in Figure 3-10, is the default master page for most non-publishing sites in SharePoint 2010. It is also the default system master page in both SharePoint Foundation and SharePoint Server.

Figure 3-10

Figure 3.10. Figure 3-10

default.master

The default.master page in SharePoint 2010 should look familiar to you if you worked with SharePoint 2007. Both visually and in the code, this master page looks like the default.master page seen in collaboration sites in SharePoint 2007, the previous version of SharePoint. Use this master page if you are using or require a legacy (2007) interface for your site and you will not be using the ribbon.

The inclusion of this master page in SharePoint Foundation and SharePoint Server ensures that upgrading from SharePoint 2007 to SharePoint 2010 is an easy process. It is automatically used when you upgrade a SharePoint 2007 site to SharePoint 2010. Although it does not include the ribbon, you could add the ribbon and other SharePoint 2010 user interface content placeholders.

As shown in Figure 3-11, when default.master is applied to a SharePoint 2010 team site, the look and feel transforms to the familiar "baby blue" branding of SharePoint 2007.

Figure 3-11

Figure 3.11. Figure 3-11

minimal.master

The minimal.master page is best suited for pages with minimal branding and navigation. The minimal.master is used with search pages and Office web applications. Because this master page does not include the ribbon or navigation, you should use it for pages that require a lot of real estate.

Figure 3-12 shows a search page with minimal.master applied.

Figure 3-12

Figure 3.12. Figure 3-12

Note

The search pages use different master pages from the rest of your site. If you customize your site, you will need to create a new master page based on the minimal master page. This way, you can add a reference to your custom styling in the minimal.master, which is the master page that search pages use.

simple.master

simple.master is the master page used for error and login pages. It lives in the file system and is not available in the master page gallery. If you are creating a custom login or error page, you will want to use the simple.master page. Figure 3-13 shows an error page with simple.master applied.

Figure 3-13

Figure 3.13. Figure 3-13

MWSDefaultv4.master

The MWSDefaultv4.master is found in the master page gallery of meeting workspace sites. It is almost identical to the v4.master with the exception of a couple of content placeholders such as the MeetingNavigator, shown in the left navigation area in Figure 3-14.

nightandday.master

The nightandday.master page, seen below in Figure 3-15, is only available in SharePoint Server 2010. It contains controls specialized for publishing web content management. You learn more about this master page in Chapter 4.

Figure 3-14

Figure 3.14. Figure 3-14

Other Master Pages

There are more master pages included in SharePoint Foundation Server and SharePoint Server 2010, such as legacy (SharePoint 2007) master pages for managing application pages for non-UI upgraded sites. Master pages such as applicationV4.master and mysite.master are for specific types of scenarios or sites, live in the file system, and are customized using development tools and techniques.

Modifying the Default Master Page

The v4.master page is included in every site in both SharePoint Foundation and SharePoint Server 2010. It can be used with publishing sites and non-publishing sites. You learned earlier that master pages contain HTML, CSS, SharePoint controls, and ContentPlaceholder controls.

It is a best practice to make a copy of a default master page and make changes in the copy rather than directly in the original file, v4.master. This protects your work from being overwritten by software patches.

Figure 3-15

Figure 3.15. Figure 3-15

You can create a copy of v4.master with either the browser or SharePoint Designer. If you use SharePoint Designer, don't copy the file and paste it back into the gallery. You should create a completely new master page in order to break all ties from the original file. In SharePoint Designer 2010, a new function is available that allows you to import and export files.

If you make changes directly to v4.master and try to save the file, you will receive the warning message seen earlier in the chapter in Figure 3-8. Although editing a default master page should not be part of a permanent solution, it can be a fast way to help you troubleshoot or test a change.

Figure 3-18

Figure 3.18. Figure 3-18

When you change a default file from the site definition, SharePoint Designer provides an indicator that the file is changed from the original site definition with a blue icon to the left of the file, shown in Figure 3-18.

You can always revert to the original file by right-clicking the customized file and selecting "Reset to Site Definition" from the context menu. The Site Definition Page Warning dialog box will appear, as shown in Figure 3-19.

Figure 3-19

Figure 3.19. Figure 3-19

Click Yes and SharePoint will re-link the file to its site definition file. For backup reasons, a copy of the customized file is renamed and stored in the same folder.

Applying a New Master Page

In order for your site to reflect any changes made to your master page, you will need to apply the master page to your site. You can do this through the browser or by using SharePoint Designer.

CREATING CUSTOM MASTER PAGES

You may find that modifying the default master pages is too constraining for your needs. If this is the case, you can create a custom master page for more flexibility. A custom master page is created from your own HTML and then required code and content placeholders are added in appropriate areas. Before you decide to implement a custom master page in your site, consider the following points:

  • Testing Time — Microsoft already tested the functionality and user experience of default SharePoint master pages. If you create your own master page, you will need to identify key areas of functionality (i.e., adding web parts, adding new calendar entries, etc...).

  • Loss of Default Functionality — Your custom markup may change the way default components of SharePoint work (i.e., the ribbon scroll or the page editing experience). Identifying these areas early and communicating the risk of losing functionality to decision makers is critical to your project's success.

Required Placeholders

As previously mentioned, a master page must have all of the required content placeholders in the code, even if you are not going to use them. The following table lists the required placeholders, their placement in the document flow, and their descriptions:

PLACEMENT

PLACEHOLDER NAME

DEFAULT CONTENT/FUNCTION

<head>

PlaceHolderPageTitle

Title of the site. Found in head of master page.

<head>

PlaceHolderAdditionalPageHead

Placeholder in the head section of the page used to add extra components such as JavaScript and CSS.

<head>

PlaceHolderTitleAreaClass

The CSS for the title area (now in the head tag).

***Changed since 2007. Make sure to move to <head> when upgrading***

Anywhere

PlaceHolderBodyAreaClass

A content placeholder for adding additional CSS style to the page.

Ribbon

SPNavigation

Control used for additional page editing controls. (Was used as a Publishing console control in 2007.)

Ribbon

PlaceHolderGlobalNavigation

Breadcrumb control in the Ribbon.

Ribbon

PlaceHolderGlobalNavigationSiteMap

Placeholder to show the Global Site Map (displayed as the Popout menu in the ribbon).

TitleRow

PlaceHolderSiteName

Name of the site where the current page resides.

TitleRow

PlaceHolderPageTitleInTitleArea

Title of the page, which appears in the title area on the page.

TitleRow

PlaceHolderPageDescription

Description text from the page's definition.

TitleRow

PlaceHolderSearchArea

Location of search controls.

Top Nav

PlaceHolderTopNavBar

Container used to hold the top navigation bar.

Top Nav

PlaceHolderHorizontalNav

The navigation menu that is inside the top navigation bar.

Left Nav

PlaceHolderQuickLaunchTop

Top of the Quick Launch menu that contains backwards compatible HTML for legacy (2007) sites.

Left Nav

PlaceHolderQuickLaunchBottom

Bottom of the Quick Launch menu that contains backwards compatible HTML for legacy (2007) sites.

Left Nav

PlaceHolderLeftNavBarDataSource

Location of the data source used to populate left navigation.

Left Nav

PlaceHolderCalendarNavigator

Date picker used when a calendar is visible on the page.

Left Nav

PlaceHolderLeftNavBarTop

Top section of the left navigation bar.

Left Nav

PlaceHolderLeftNavBar

Container for Quick Launch (current navigation).

Left Nav

PlaceHolderLeftActions

Additional objects above the Quick Launch bar, "Recent Items" in Wiki pages.

Main Body

PlaceHolderMain

Main content of the page.

Main Body

PlaceHolderTitleBreadcrumb

Breadcrumb text for the breadcrumb control.

Bottom (Not Visible)

PlaceHolderFormDigest

Container where the page form digest control is stored.

Bottom(Not Visible)

PlaceHolderUtilityContent

Additional content at the bottom of the page. This placeholder should be placed outside of the form tag.

Legacy

PlaceHolderPageImage

Not present in SharePoint 2010 user interface, but required for legacy master pages.

Legacy

PlaceHolderTitleLeftBorder

 

Legacy

PlaceHolderMiniConsole

 

Legacy

PlaceHolderTitleRightMargin

 

Legacy

PlaceHolderTitleAreaSeparator

 

Legacy

PlaceHolderNavSpacer

 

Legacy

PlaceHolderLeftNavBarBorder

 

Legacy

PlaceHolderBodyLeftBorder

 

Legacy

PlaceHolderBodyRightMargin

 

Unused Placeholders

Some of the required placeholders may not be necessary for your design, so what do you do with them? Hide them! Include them inside an <asp:Panel> control you add to the page and set the control's Visible attribute to False as shown in the following code snippet. Since the <asp:Panel> control is not visible, the ContentPlaceHolder controls within it and their corresponding Content controls will not be rendered to the browser.

<!--Hidden Placeholders -->
<asp:Panel visible="false" runat="server">
<!-- Top Nav -->
<asp:ContentPlaceHolder id="PlaceHolderHorizontalNav" runat="server"/>
<asp:ContentPlaceHolder id="PlaceHolderTopNavBar" runat="server"/>
<!-- Left Nav -->
<asp:ContentPlaceHolder id="PlaceHolderQuickLaunchTop" runat="server"/>
<asp:ContentPlaceHolder id="PlaceHolderQuickLaunchBottom" runat="server"/>
<asp:ContentPlaceHolder id="PlaceHolderLeftNavBarDataSource" runat="server" />
<asp:ContentPlaceHolder id="PlaceHolderCalendarNavigator" runat ="server" />
<asp:ContentPlaceHolder id="PlaceHolderLeftNavBarTop" runat="server" />
<!-- For adding CSS to child pages -->
<asp:ContentPlaceHolder id="PlaceHolderBodyAreaClass" runat ="server"/>
<asp:ContentPlaceHolder id="PlaceHolderTitleAreaClass" runat ="server"/>
<!-- Required for Legacy UI -->
<asp:ContentPlaceHolder id="PlaceHolderSiteName" runat="server"/>
<asp:ContentPlaceHolder ID="PlaceHolderPageImage" runat="server"/>
<asp:ContentPlaceHolder ID="PlaceHolderTitleLeftBorder" runat="server"/>
<asp:ContentPlaceHolder id="PlaceHolderMiniConsole" runat="server"/>
<asp:ContentPlaceHolder id="PlaceHolderTitleRightMargin" runat="server"/>
<asp:ContentPlaceHolder ID="PlaceHolderTitleAreaSeparator" runat="server"/>
<asp:ContentPlaceHolder ID="PlaceHolderNavSpacer" runat="server"/>
<asp:ContentPlaceHolder id="PlaceHolderLeftNavBarBorder" runat="server"/>
<asp:ContentPlaceHolder ID="PlaceHolderBodyLeftBorder" runat="server"/>
<asp:ContentPlaceHolder id="PlaceHolderBodyRightMargin" runat="server" />

</asp:Panel>

Required Controls

There are several required controls for a SharePoint master page to function. When you create a custom master page or are troubleshooting any errors with a modified master page, make sure that these controls are in place.

PLACEMENT

CONTROL

DESCRIPTION

<head>

SPPageManager

Controls routing commands to page components such as the ribbon and toolbars.

<head>

ScriptLink

Creates a reference to the SharePoint ECMAScript libraries.

<body>

ScriptManager

Manages all of the ECMAScript functions on the page and their ability to communicate back to the server without refreshing the page in the browser.

Note

ECMAScript is the name of the official standard from which Microsoft Jscript and JavaScript are derived.

Broken Master Pages

It is inevitable, as you are learning the ins and outs of customizing with SharePoint Designer, that you will break a master page. Broken master pages are not actually broken; rather, they cannot be rendered in the browser. Use the following list of the most common problems to help you troubleshoot broken master pages.

  • Required Content Placeholders — You must have all required content placeholders in the code of the master page even if you are not using them.

  • Typos — Be sure to copy and paste code from an existing, working master page instead of typing the code manually. This ensures you do not introduce a typo. If you are copying and pasting code from a browser, such as example code you find on the Internet, paste the code into Notepad first to remove any error-causing formatting. Then, copy and paste the code from Notepad into the destination master page. Notepad is usually available from the Accessories folder on your Start menu.

  • Duplicate Content Placeholders — Duplicate content placeholders are easy to spot in SharePoint Designer, as well as the browser, since an error will be generated when the page is loaded in either application.

    Note

    Opening master pages outside of a SharePoint environment can change the contents of the master page. When this happens, you will receive an error. Often the error is due to a typo in the first few lines of code in the master page. In Figure 3-20, the references to content template pages are incorrect because they are missing the leading tilde and forward slash (~/).

    Figure 3-20

    Figure 3.20. Figure 3-20

    Adding ~/ after the quotation mark to make src="_look like src="~/_ will fix this error and allow you to open your pages without error. The corrected code is shown in Figure 3-21.

    Figure 3-21

    Figure 3.21. Figure 3-21

EXAMPLE SCENARIOS

Regardless of your role, as you work with SharePoint, you will encounter requests to change the look and feel of your site. It takes time and practice to understand whether user interface requests are a big effort or a minor change.

The following scenarios and exercises are meant to give you experience in three different types of user interface requests. Each solution has its own set of issues depending on browser and content requirements.

Scenario 1: Fixed Width Layout

In Figure 3-22, the out-of-the-box layout of the v4.master is represented by Layout A. A common user interface change request is to optimize a site for a target screen resolution (usually 1024 pixels by 768 pixels, the most common screen resolution). This changes the layout of a site so that pages are fixed and centered as shown in Layout B.

Figure 3-22

Figure 3.22. Figure 3-22

Note

A fixed-width design is a layout optimized for a target screen resolution. It is generally used to control the presentation of content regardless of the size of a user's window. There are several benefits to using this type of layout:

  • Readability — A fixed width shortens lines of text and makes reading easier.

  • Consistency — Content placement is predictable regardless of browser size. A controlled space allows for the communication of content relationships.

  • Aesthetics — It simply looks good.

A fixed-width design can be beneficial with managed content but can be troublesome when applied to collaboration sites because it can impact the intended functionality.

  • User Adoption — Users will be responsible for choosing appropriate sizes for content. If users are not comfortable making design decisions, they may choose to collaborate through e-mail or by phone instead of through the SharePoint site.

  • Design strength — Any solution that fixes the width of the page impacts the out-of-the-box SharePoint functionality, including the scrolling of the ribbon, browser compatibility, and the behavior of large content.

Note

FixedWidth.master is available for download from the Wrox site and includes additional styling with CSS comments.

Scenario 2: Changing the Location of the Search Box

In this scenario, the search control needs to be moved to a new location within the master page.

Scenario 3: Registering External CSS

The following example fulfills another common design request. Although you will learn more about CSS styles in Chapter 5, you may be asked to update your master page to reference external CSS files. For this example, an external style sheet and images are provided at the Wrox download site. A reference to the style sheet simply needs to be added to the master page so that the top navigation's tabs are styled with rounded top corners.

SUMMARY

This chapter explained how a typical SharePoint Page is constructed. You saw the power of Master Pages to change the look and feel of your site. You also found out:

  • How to edit and apply master pages.

  • You can change the way SharePoint looks from the out-of-the-box style.

  • Points to consider when creating a custom master page.

This is only the first step in understanding how to customize the look and feel of your SharePoint 2010 site with SharePoint Designer. In the next chapter, you will learn about Web Content Management and the Publishing pages of SharePoint 2010.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
52.15.129.253