Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

Masterpage galleries in subsites

  Asked By: Tarang    Date: Feb 08    Category: Sharepoint    Views: 4548

I loaded a master page in a masterpage gallery in a subsite and tried
to reference that masterpage.
It was not given to me as an option when I went to the "master page"
option in the site settings of the sub site.
Anyone know why those galleries exist, if we cannot reference the
master pages it contains?



3 Answers Found

Answer #1    Answered By: Bhairavi Damle     Answered On: Feb 08

The masterpage  link in site  settings only exists if you have publishing
turned on. Publishing provides a system of inheritance where all the
masterpages are stored in the master  Page gallery  at the top level site
of the site collection. To use the masterpages in the local site
gallery you either need to reference  it directly in the masterpage
attribute of the aspx page. That can be done programmatically or
through SharePoint designer.

Answer #2    Answered By: Leeann Hull     Answered On: Feb 08

What if I wanted to store a custom layout page  in the site  level masterpage
gallery and wanted to reference  that as well..?
I haven't seen a place on a masterpage  that references a layout page..am I
missing something?

Answer #3    Answered By: Vaasu Radhakrishna     Answered On: Feb 08

It's the other way around. The @Page declaration at the top of the
layout page  references the master  page. Most pages  simply reference  a
replaceable token ~masterurl/default.master, but you can also directly
reference a master page in the masterpage  gallery by substituting
~site/_catalogs/masterpage/name of the masterpage.

Didn't find what you were looking for? Find more on Masterpage galleries in subsites Or get search suggestion and latest updates.