Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

need to create page layout using a different master page

  Asked By: Nicole    Date: Nov 11    Category: Sharepoint    Views: 2595

I need to create a page layout that uses a different master page from
the custom and default master pages. But the dialog box that lets me
choose the option "Specific Master Page" instead of default or custom
will only let me browse to the file system to find the master page.
But I created the master page with Sharepoint Designer, which means it
won't let me select it. How do I get around this?



3 Answers Found

Answer #1    Answered By: Elaina Suarez     Answered On: Nov 11

Even if you find  a way to select  a different master page  I don't think
it will help. If you look at the coding of a page layout  there is no
masterpagefile declaration in the @Page tag at the top of the page.
That's because it gets the setting by inheriting from a PublishingPage
object. Inheriting from that object is required for page layout
functionality to work. The PublishingPage object class is hard coded to
use the custom master  (site master). Even if you override it I think
the default  setting in the class is the one it uses. I don't think
there is any way to get around that.

Answer #2    Answered By: Kacey Russo     Answered On: Nov 11

Does that mean there's no way to use a different master page  from
the custom master  page for some of the content pages?

Answer #3    Answered By: Rebecca Lewis     Answered On: Nov 11

The only possibility that I can think of would be to subclass the
PublishingPage object class, override the customweburl setting, and use
that class for the custom layout  page. I don't know if its possible or
not since I don't know if you can inherit from PublishingPage.

Otherwise, no you can't use a different masterpage for layout pages  in
the pages document library.

Didn't find what you were looking for? Find more on need to create page layout using a different master page Or get search suggestion and latest updates.