Search This Blog

Wednesday, March 11, 2015

Create Custom using SharePoint 2010 Master Page

Creating a SharePoint 2010 master page for a custom footer is very easy to do. Follow these simple steps to make a custom footer for your site.
For this exercise, we will be using a Publishing site. The difference between a Publishing site and a team site is the added layer of checking in/out files before publishing or previewing a live version. If you are not using a Publishing site, please disregard the related steps below.
  1. Copy Master Page
    1. Open site using SharePoint Designer 2010
    2. Click Master Pages in the left navigation pane
    3. Right click v4.master and select Copy, then paste
  2. Rename the New Master Page
    1. From the Ribbon, click Rename
    2. Type “Customfooter.master” (or any other name you choose)
  3. Edit the CSS Inline
    1. From the Ribbon, click Check Out
    2. Then, click Edit File
    3. Select Split View
    4. In code, find: <SharePoint:DeveloperDashboard runat=”server”/>.
    5. Add the following code just below the code listed above:
      <div class=”s4-notdlg” style=”clear: both; background-color: #FEAD30; padding: 10px;”> ©Copyright XXXX 2013, All Rights Reserved </div>Image
    6. Click Save. If prompted, click Yes to overwrite existing site definition.
  4. Apply Default Master Page
    1. Click Master Pages from left navigation pane
    2. Select the row for Customfooter.master (or whatever you named your new file), BUT NOT the title itself.
    3. From the Ribbon, click Set to Default.
    4. Then, click Check In.
  5. View Your Changes
    1. Click Save
    2. Open site in browser, or click Preview in Browser
how to create custom master page in sharepoint 2010 using visual studio 

In this Article I will explain how to create and deploy master page using visual studio 2010.
I am created an Empty solution with name MasterPageTest as shown Below.
 Now right click on the solution add new item Module as shown below

 Now we can able to see the txt file
              Now I am rename sample.txt as SampleMaster.Master.
              After completing these steps.
              Go to site setting->MasterPage->

             Select the V4 master page Download a copy in to your system.
            Copy that code and paste in to SampleMaster.Master.
             In Element.xml we have to modify the code like this

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<Module Name="TestExample" Url="_catalogs/masterpage">
<File Path="TestExample\SampleMaster.Master" Type="GhostableInLibrary" Url="TestExample/SampleMaster.Master" IgnoreIfAlreadyExists="TRUE" />
</Module>
</Elements>
          I am adding the H1 tag DotNet SharePoint Site in my Master Page.

           Deploy the Solution,After Deploying Successfully.

            Go to site setting → Galleries->
                                         
                     We can able to see the Module name with Pending Status  

                  Click on that Module name select Approved option Click ok  

      We have active two features,One is in Site Setting->Site Collection administration ->Site         Collection features.
                             

     In Site Actions->Manage Site Features.

                                                                      

  
         After Activating go to Look and Feel ->MasterPage
        Select our master we deployed from VS2010  
                             
        After Selecting master page at site master page and system master page Click ok .

       Finally we can able to see my master page .

- See more at: http://www.dotnetsharepoint.com/2013/12/how-to-create-custom-master-page-in.html#sthash.dRm3jtU4.dpuf

How to apply custom master page and theme to all SharePoint 2010 sub sites?

How to apply custom master page and theme to all sub sites in SharePoint 2010?


1. Go to Site Actions | Site Settings
2. Click on Manage Site Features
manage_site_features
3. Activate SharePoint Server Publishing
activate_sharepoint_2010_server_publishing
4. Go to Site Actions | Site Settings again and under Look and Feel click on Master Page
master_pages 
5. In Site Master Page click on the drop down and select your custom master page. If your not sure how to create custom master page, please see :http://virtualizesharepoint.com/category/sharepoint-2010-branding/
Selecting Custom Master Pages in SharePoint 2010
6.  Put a check in Reset all subsites to inherit this site master page setting and click OK in the bottom of the page
reset_all_subsites_to_inherite_this_master_page_settings_sharepoint_2010

This will apply custom master page to all sub sites in SharePoint 2010


No comments:

Post a Comment