Search code examples
asp.netmaster-pages

Is it possible to create a master page which selects another master page?


I have a master page with name MasterPage.master.

Now I want to create another master page (MasterPage2.master) that its MasterPageFile is MasterPage.master, But when I create MasterPage2 and then create a webform from MasterPage2, there isn't any ContentPlaceHolder in this webform.

Please explain for me...


Solution

  • What you're looking for is nested master pages.
    Google it and you'll have a ton of tutorials. Top 2 results from google:

    http://msdn.microsoft.com/en-us/library/x2b3ktt7(v=vs.100).aspx
    http://msdn.microsoft.com/en-us/library/bb547109(v=vs.100).aspx