Showing posts with label master pages. Show all posts
Showing posts with label master pages. Show all posts

Thursday, March 24, 2011

Customise SharePoint v4 Master Page to Hide Recycle Bin and All Site Content Links

The following steps walk you through the process of making this common SharePoint customization:

  • Create a custom master page SharePointMalaya.master from v4.master. For details information on how to create this master page, see Customise SharePoint v4 Master Page to Add Footer.
  • Edit the CustomFooter.master file by clicking on the Edit File button.
  • From the ribbon, click the Skewer Click button, as shown in Figure below. This enables you to see the CSS that is being applied to a specific object.

image

  • With Skewer Click selected, hover over the area near where the Recycle Bin and All Site Content links are located. Move your mouse around the area and you should see the name PlaceHolderQuickLaunchBottom appear faintly.

image

  • Select it and another window will open displaying a list of styles. Click the style called ul.s4-specialNav…, as shown in
    figure below.

image

  • Before you can edit the CSS, you must first add a new panel to SPD. From the ribbon, click the Style tab and select the CSS Properties button.
  • When the new panel opens, you’ll see the top section is called Applied Rules. The style you want to modify (.s4specialNavLinkList) should already be selected as shown in figure below.

image

  • Right click the style and select New Style Copy.

image

  • At the top of the New Style dialog shown in figure below, set the new style to be defined in the “Current page”. Be sure to check the box “Apply new style to document selection”. Then select the Layout category and set the “visibility” to “hidden”. Click OK.

image

  • Save the changes made to the master page.
  • Now open your site in the web browser, you’ll see that a footer has been applied to your site, as shown below:

image

Customise SharePoint v4 Master Page to Add Footer

The following are steps of creating a custom master page to add a footer by using SharePoint Designer 2010.

  • Open your site in SharePoint Designer 2010 and click the Master Pages link in the Navigation pane.
  • Right click v4.master and select Copy.

image

  • Right click and paste another copy of the file into the Master Pages gallery.
  • From the Master Pages gallery, click next to the filename for the master page that was just
    created. From the ribbon, click the Rename button. Rename the file SharePointMalayaFooter.master.

image

  • Select the file SharePointMalayaFooter.master and then, from the ribbon, click the Edit File button.
  • Ensure that either the Split or Code view is showing. Near line 624, after <SharePoint:DeveloperDashboard runat=“server”/>, add the following code snippet:

<div class="s4-notdlg" style="clear: both; background-color:#FEAD30; padding: 10px;">&copy; Copyright 2011 SharePoint Malaya</div>

image

  • After you’ve made the change, save the fi le by clicking the Save icon in the upper left-hand corner of the screen. You will get a dialog that warns you that you are about to customize the file from the site definition. Click Yes to continue.

image

  • Click the Master Page link again from the Navigation pane on the left to return to the Master Pages gallery.
  • To apply the changes to the site, select SharePointMalayaFooter.master and then, from the ribbon, click the Set as Default button.
  • Now open your site in the web browser, you’ll see that a footer has been applied to your site, as shown below:

image

Thursday, February 3, 2011

Turn Off Warning Message On Unsupported Browsers in SharePoint 2010

Browser support in SharePoint 2010 has been greatly improved over SharePoint 2007, check out Technet’s Browser Support Matrix for SharePoint 2010. However Internet Explorer 6 (IE6) and other commonly used browsers are not browsers SharePoint 2010 supports from a content-authoring perspective. When you open a SharePoint page using IE6 browser, the following simple message will be displayed in the message box:

“Your Web browser will have problems displaying this web page. Changes to the sites may not function properly. For a better experience please update your browser to its latest version.”

WarningLegacyBrowser

Let say you are able to create a specific master page that works for anonymous IE6 users but how to turn off the warning message for all users with legacy unsupported browsers like IE6?

It’s simple! Find the following line at the bottom of the out-of-the-box master pages:

<SharePoint:WarnOnUnsupportedBrowsers runat=”server”/>

If you want to turn off the warning message for all users, you can simply remove it from master pages.

Wednesday, February 2, 2011

How To Turn Off Master Pages Applying to Application Pages

You may not want your custom branding to apply to the application pages, normally the way I do this is by not applying custom master page to SharePoint 2010 as the System Master Page. But wait, although this method prevents the application pages from showing the custom branding, but it also prevents the branding from showing on any nonpublising page too :(

I found a better way to do this that is by stop master pages from applying to application pages by turning off the feature completely from Central Administration, as follows:

  • Open Central Administration on the SharePoint server.
  • Under Application Management, click Manage web applications.
  • Select the desired web application from the list, and then from the ribbon, click General Settings.
  • In the dialog that appears, scroll down to Master Page Setting for Application _Layouts Pages and select No.
  • Scroll to the bottom of the dialog and click OK.

MasterPageSettingsForLayoutPage

    Now custom master pages for this entire web application will not apply to the application pages.