SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to change the way a <title> displays. Currently it just displays the page name in most cases "Home". What I would like it to look like is "Site Collection Name - Page Name" It seems to work fine when I'm working with non-publishing sites and I noticed both use the same master page tag <title id="onetidTitle"><asp:ContentPlaceHolder id="PlaceHolderPageTitle" runat="server"/></title>

So far the things I've tried:

  1. Adding a title in the SharePoint Page Properties (<--Doesn't Show up anywhere)
  2. Adding the title manually before the <asp:ContentPlaceHolder id="PlaceHolderPageTitle" runat="server"/> (<-- Also didn't get recognized after publishing)
share|improve this question
up vote 2 down vote accepted

I also noticed that if you put some value before the placeholder in master page, it does not work. However, in your page template, if you put something like below, it will show title of the web and title of the page.

<asp:Content contentplaceholderid="PlaceHolderPageTitle" runat="server">
    <SharePoint:ProjectProperty runat="server" id="ProjectProperty1" Property="Title" /> - <SharePoint:fieldvalue id="PageTitle" FieldName="Title" runat="server"/>

Please note that control shown above displays current web’s title, if you have to write a custom control.

share|improve this answer
That did the trick, thanks Ashish – user5991 Jan 17 '12 at 23:47

It is also possible, using an encoded literal. Like this:

<title id="onetidTitle">
    <SharePoint:EncodedLiteral runat="server" text="My Site" EncodeMethod='HtmlEncode' />
    <asp:ContentPlaceHolder id="PlaceHolderPageTitle" runat="server"/>
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.