Editing SharePoint 2013 Master Pages directly


Microsoft has revamped the way master pages work/behave in SharePoint 2013 and developers migrating from 2010 will sure have some surprises unless you read a bit on the new updates to successfully make changes to masterpages in SharePoint 2013.

I wont go deep into the concepts behind the changes, but will highlight a thing or 2 on the fundamental changes in SharePoint 2013 compared to 2010:

  1. SharePoint 2013 associates a HTML file to every master page and by default you are not allowed to edit the .master page directly.
  2. SharePoint Designer 2013 doesn’t have the visual view any more and changes can either be viewed in the browser or through the (Design Manager, which is of course through browser as well!).
  3. As like 2010, you don’t need to explicitly approve/publish the .master page.  In other words, its enough if you approve/publish the .html page which will automatically publish the .master page.
  4. The name of the .master page will be same as the .html page.

Continue reading

3,751 total views, no views today

Adding a Code-Behind for SharePoint 2010 Master Page using Visual Studio 2012

Too often we land in scenarios, where we require the flexibility to handle common logic in SharePoint  that requires wiring a code behind for the SharePoint 2010 MasterPage, which is never a straightforward and easy step to perform.

In this article, let’s look at the steps to add a code-behind file to a SharePont 2010 MasterPage, using the SharePoint templates available in Visual Studio 2012 IDE.

Continue reading

6,511 total views, no views today