views:

384

answers:

1

So I've setup a site collection using the Publishing Portal template and stubbed out a prototype site structure including three tiers. At the second tier I've created a Publishing site and developed a custom master page for the site and its third tier children. The problem is that the banner graphic on a few pages should be modified to be inconsistent. Then I add two new ContentPlaceHolder controls to my master page in SharePoint Designer and use the SharePoint interface to create my new publishing pages. Finally, I verify in SharePoint Developer that they have the correct master page, add my asp:content controls to the pages and insert the page-specific banner graphic. The only problem is that the master page default content continues to be rendered in all page instances. If I create a new page from the master page in SharePoint designer, I get a different base class in the Page declaration than those created within the Publishing site. Do publishing sites ignore any non-SharePoint contentPlaceHolders?

+1  A: 

There is nothing like SharePoint ContentPlaceHolders & non-SharePoint ContentPlaceHolders. When you add a Default content to the Master Page ContentPlaceholder and if you dont override it in the Content Page then it will be visible in all the Pages that use that Master Page. Only way to get rid of it is to Override those Content Place Holder with empty content in the Content Pages. As overriding contentPlaceHolder in all the Pages is not an good Aproach. What I recommend is not to place conent in the ContentPlaceHolder of the Master Page but instead , put the content in the Content Control page of the Pages, so that Content doesn't come in all page but only the page that needs it. Yes it not a good to put the exact same content in multiple page. but in your case that is only the Option. May be you try to wrap the content in to a User Control so that the code can be updated only one place

Kusek
What I've found in further pursuit of this issue is that I lacked an understanding of the Publishing site dependency chain. Apparently publishing sites require you to use layout pages (.aspx files) which inherit from your master page. My problem stemmed from the fact that I was attempting to modify a master page in a child site that had a local master page. Since my publishing pages were configured on the root site layout pages, changes to the local master page had no effect. Now I need to know if I can have multiple root master pages or create local layout pages from a local master.
ValueCoder