Application master page files in SharePoint 2010


Category : SharePoint 2010

The bane of my existence, in branding SharePoint 2007 sites, is the application.master page. They always cause me issues. Microsoft made a clear path to creating custom master pages for a SharePoint site, but completely left out application pages. Of course, SharePoint developers figured this out and use custom http modules However, that is a pain to do because it means creating two separate master pages for one application (really defeats the purpose of master pages). Not to mention there are all kinds of issues with creating application.master pages (my favorite is how some application pages break when Ajax functionality was implemented).
Thus, I was extremely happy when I saw the ability to update the application master page in SharePoint 2010. I took a look at one of the application pages and noticed the following tag: “DynamicMasterPageFile”. This setting uses the same concepts of regular SharePoint pages in relation to master pages. No more custom application master pages needed!
Oh happy day! Loving SharePoint 2010 more and more every time I use it. I hope all my clients upgrade soon.

Comments (6)

After a SharePoint upgrade, what is the best way to deal with the module no longer working?

i.e. my settings.aspx pages (admin pages) have DynamicMasterPageFile=”~masterurl/default.master” within them however they are actually using layoutsv3.master

Why is this happening? thx

Hi David,
~masterurl/default.master is what they call a dynamic token in SharePoint. It is not a physical path. SharePoint actually does a string replacement at runtime to replace default.master with layoutsv3.master. The reason they do this is so you can change the masterpage in the UI (assuming you are running SharePoint Server and not just SharePoint Foundation). It’s a very nice thing to be able to switch master pages in the UI under Site Settings – Master Pages.
For more information on dynamic tokens, check out a magazine article I wrote for SharePoint 2007. It is the same concept in 2010.


Just starting to work with Application Pages. I have not used sharepoint 2007 so I am not sure how application pages navigation behaved previously.

What I am trying to find out it is if there is a way to modify the Breadcrumbs in the master page.

Currently when I access ApplicationPage1.aspx my breadcrumbs will display:

SharepointSiteName -> ApplicationPage1

if I link within my ApplicationPage1.aspx to my ApplicationPage2.aspx my breadcrumbs will display:

SharepointSiteName -> ApplicationPage2

I would like it to display:
SharepointSiteName -> ApplicationPage1 -> ApplicationPage2

so that I can navigate back.

I Created a Custom Layouts Page “osssearchresultsNew.aspx” just replica of “osssearchresults.aspx”. Now i Created a custom MasterPage “search.master” for my Custom Layouts page(osssearchresultsNew.aspx). Then what will be my DynamicMasterPageFile and how to map to my custom master Page(search.master)

The Search Settings page (enhancedSearch.aspx) has the following master Url: MasterPageFile=”~/_layouts/application.master”
Do we still need the HttpHandlr like in SP 2007 ?

This is one of the best articles so far I have read online. No crap, just useful information. Very well presented. Its really helpful for me and following link also helped me to complete my task…