0

I have a requirement for a non-standard layout of web-part zones so I have created custom page layout which accommodates my needs. I created a test page and everything has worked perfectly except for one thing: The page title displays twice like this:

Test Test

I can't find anything in the code to account for this. Can anyone with a better knowledge of HTML tell me what I've done wrong?

    <body>
        <script type="text/javascript">//<![CDATA[ var submitHook = function () { return false; }; theForm._spOldSubmit = theForm.submit; theForm.submit = function () { if (!submitHook()) { this._spOldSubmit(); } }; 

        //]]>
        </script>
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderTitleBreadcrumb" runat="server">-->
            <!--SPM:<SharePoint:ListSiteMapPath
                runat="server"
                SiteMapProviders="SPSiteMapProvider,SPContentMapProvider"
                RenderCurrentNodeAsLink="false"
                PathSeparator=""
                CssClass="ms-breadcrumb"
                NodeStyle-CssClass="ms-breadcrumbNode"
                CurrentNodeStyle-CssClass="ms-breadcrumbCurrentNode"
                RootNodeStyle-CssClass="ms-breadcrumbRootNode"
                NodeImageOffsetX="0"
                NodeImageOffsetY="289"
                NodeImageWidth="16"
                NodeImageHeight="16"
                NodeImageUrl="/_layouts/15/images/fgimg.png?rev=44"
                RTLNodeImageOffsetX="0"
                RTLNodeImageOffsetY="312"
                RTLNodeImageWidth="16"
                RTLNodeImageHeight="16"
                RTLNodeImageUrl="/_layouts/15/images/fgimg.png?rev=44"
                HideInteriorRootNodes="true"
                SkipLinkText=""/>-->
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderTopNavBar" runat="server">-->
            <!--SPM:<SharePoint:AspMenu 
            ID="TopNavigationMenu" 
            Runat="server" 
            EnableViewState="false"
            DataSourceID="topSiteMap"
            AccessKey="&#60;%$Resources:wss,navigation_accesskey%&#62;"
            UseSimpleRendering="true"
            UseSeparateCss="false"
            Orientation="Horizontal"
            StaticDisplayLevels="2"
            AdjustForShowStartingNode="true"
            MaximumDynamicDisplayLevels="2"
            SkipLinkText=""/>-->
            <!--PS: Start of READ-ONLY PREVIEW (do not modify)--><link rel="stylesheet" type="text/css" href="/_layouts/15/1033/styles/menu-21.css" /><div id="zz7_TopNavigationMenu" class=" noindex ms-core-listMenu-horizontalBox"><ul id="zz9_RootAspMenu" class="root ms-core-listMenu-root static"><li class="static"><a class="static menu-item ms-core-listMenu-item ms-displayInline ms-navedit-linkNode" tabindex="0" title="Default Publishing Site" href="#" accesskey="1"><span class="additional-background ms-navedit-flyoutArrow"><span class="menu-item-text">Default Publishing Site</span></span></a></li></ul></div><!--PE: End of READ-ONLY PREVIEW-->
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderPageTitleInTitleArea" runat="server">-->
            <!--SPM:<SharePoint:SPTitleBreadcrumb
                    runat="server"
                    RenderCurrentNodeAsLink="true"
                    SiteMapProvider="SPContentMapProvider"
                CentralAdminSiteMapProvider="SPXmlAdminContentMapProvider"
                SkipLinkText="">-->
            <!--PS: Start of READ-ONLY PREVIEW (do not modify)--><span id="ctl00_DeltaPlaceHolderPageTitleInTitleArea">Home</span><!--PE: End of READ-ONLY PREVIEW-->
            <!--SPM:<PATHSEPARATORTEMPLATE>-->
            <!--SPM:<SharePoint:ClusteredDirectionalSeparatorArrow runat="server"/>-->
            <!--SPM:</PATHSEPARATORTEMPLATE>-->
            <!--SPM:</SharePoint:SPTitleBreadcrumb>-->
            <!--CS: Start Page Field: Title Snippet-->
            <!--SPM:<%@Register Tagprefix="PageFieldFieldValue" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
            <!--MS:<PageFieldFieldValue:FieldValue FieldName="fa564e0f-0c70-4ab9-b863-0177e6ddd247" runat="server">-->
            <!--ME:</PageFieldFieldValue:FieldValue>-->
            <!--CE: End Page Field: Title Snippet-->
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderPageDescription" runat="server">-->
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderSearchArea" runat="server">-->
            <div id="searchInputBox">
                <!--SPM:<SharePoint:DelegateControl runat="server" ControlId="SmallSearchInputBox"/>-->
                <!--PS: Start of READ-ONLY PREVIEW (do not modify)--><div class="ms-webpart-chrome "><div WebPartID="00000000-0000-0000-0000-000000000000" HasPers="true" id="WebPart" width="100%" class="ms-WPBody noindex " OnlyForMePart="true" allowDelete="false" style=""><div componentid="ctl00_SmallSearchInputBox1_csr" id="ctl00_SmallSearchInputBox1_csr"><div id="SearchBox" name="Control"><div class="ms-srch-sb ms-srch-sb-border" id="ctl00_SmallSearchInputBox1_csr_sboxdiv"><input type="text" value="Search This Site..." maxlength="2048" accessKey="S" title="Search This Site..." id="ctl00_SmallSearchInputBox1_csr_sbox" autocomplete="off" autocorrect="off" class="ms-srch-sb-prompt ms-helperText" /><a title="Search" class="ms-srch-sb-searchLink" id="ctl00_SmallSearchInputBox1_csr_SearchLink" href="javascript: {}"><img src="/_layouts/15/images/searchresultui.png" class="ms-srch-sb-searchImg" id="searchImg" alt="Search" /></a><div class="ms-qSuggest-container ms-shadow" id="AutoCompContainer"><div id="ctl00_SmallSearchInputBox1_csr_AutoCompList"></div></div></div></div></div><div componentid="ctl00_SmallSearchInputBox1_csr" id="ctl00_SmallSearchInputBox1_csr"></div><div id="ctl00_SmallSearchInputBox1"></div><div class="ms-clear"></div></div></div><!--PE: End of READ-ONLY PREVIEW-->
            </div>
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderLeftNavBar" runat="server">-->
            <!--SPM:<SharePoint:DelegateControl runat="server" ControlId="QuickLaunchTop"/>-->
            <a id="startNavigation" name="startNavigation" tabIndex="-1">
            </a>
            <!--MS:<asp:ContentPlaceHolder id="PlaceHolderLeftNavBarTop" runat="server">-->
            <!--ME:</asp:ContentPlaceHolder>-->
            <!--MS:<asp:ContentPlaceHolder id="PlaceHolderQuickLaunchTop" runat="server">-->
            <!--ME:</asp:ContentPlaceHolder>-->
            <!--MS:<asp:ContentPlaceHolder id="PlaceHolderLeftNavBarDataSource" runat="server">-->
            <!--ME:</asp:ContentPlaceHolder>-->
            <!--MS:<asp:ContentPlaceHolder id="PlaceHolderCalendarNavigator" runat="server">-->
            <!--ME:</asp:ContentPlaceHolder>-->
            <!--MS:<asp:ContentPlaceHolder id="PlaceHolderLeftActions" runat="server">-->
            <!--ME:</asp:ContentPlaceHolder>-->
            <div class="ms-core-sideNavBox-removeLeftMargin">
                <!--SPM:<SharePoint:SPNavigationManager
                    id="QuickLaunchNavigationManager"
                    runat="server" 
                    QuickLaunchControlId="V4QuickLaunchMenu"
                    ContainedControl="QuickLaunch"
                    EnableViewState="false"
>-->
                <!--SPM:<SharePoint:DelegateControl runat="server" 
                        ControlId="QuickLaunchDataSource">-->
                <!--SPM:<Template_Controls>-->
                <!--SPM:<asp:SiteMapDataSource 
                                SiteMapProvider="SPNavigationProvider" 
                                ShowStartingNode="False"
                                id="QuickLaunchSiteMap" 
                                StartingNodeUrl="sid:1025" 
                                runat="server"
/>-->
                <!--SPM:</Template_Controls>-->
                <!--SPM:</SharePoint:DelegateControl>-->
                <!--SPM:<SharePoint:AspMenu
                        id="V4QuickLaunchMenu"
                        runat="server"
                        EnableViewState="false" 
                        DataSourceId="QuickLaunchSiteMap"
                        UseSimpleRendering="true"
                        Orientation="Vertical"
                        StaticDisplayLevels="3"
                        AdjustForShowStartingNode="true"
                        MaximumDynamicDisplayLevels="0"
                        SkipLinkText=""
/>-->
                <!--SPM:</SharePoint:SPNavigationManager>-->
                <!--SPM:<SharePoint:SPNavigationManager
                        id="TreeViewNavigationManagerV4"
                        runat="server" 
                        ContainedControl="TreeView"
                        CssClass="ms-tv-box"
>-->
                <!--SPM:<SharePoint:SPLinkButton runat="server" NavigateUrl="~site/_layouts/15/viewlsts.aspx" id="idNavLinkSiteHierarchyV4" Text="&#60;%$Resources:wss,treeview_header%&#62;" accesskey="&#60;%$Resources:wss,quiklnch_allcontent_AK%&#62;" 
                        CssClass="ms-tv-header"/>-->
                <!--SPM:<SharePoint:DelegateControl runat="server" ControlId="TreeViewAndDataSource">-->
                <!--SPM:<Template_Controls>-->
                <!--SPM:<SharePoint:SPHierarchyDataSourceControl
                                    runat="server"
                                    id="TreeViewDataSourceV4"
                                    RootContextObject="Web"
                                    IncludeDiscussionFolders="true"
/>-->
                <!--SPM:<SharePoint:SPRememberScroll runat="server" id="TreeViewRememberScrollV4" onscroll="javascript:_spRecordScrollPositions(this);" 
                                    style="overflow: auto;">-->
                <!--SPM:<SharePoint:SPTreeView
                                    id="WebTreeViewV4"
                                    runat="server"
                                    ShowLines="false"
                                    DataSourceId="TreeViewDataSourceV4"
                                    ExpandDepth="0"
                                    SelectedNodeStyle-CssClass="ms-tv-selected"
                                    NodeStyle-CssClass="ms-tv-item"
                                    SkipLinkText=""
                                    NodeIndent="12"
                                    ExpandImageUrl="/_layouts/15/images/tvclosed.png?rev=44"
                                    ExpandImageUrlRtl="/_layouts/15/images/tvclosedrtl.png?rev=44"
                                    CollapseImageUrl="/_layouts/15/images/tvopen.png?rev=44"
                                    CollapseImageUrlRtl="/_layouts/15/images/tvopenrtl.png?rev=44"
                                    NoExpandImageUrl="/_layouts/15/images/tvblank.gif?rev=44" 
>-->
                <!--SPM:</SharePoint:SPTreeView>-->
                <!--SPM:</SharePoint:SPRememberScroll>-->
                <!--SPM:</Template_Controls>-->
                <!--SPM:</SharePoint:DelegateControl>-->
                <!--SPM:</SharePoint:SPNavigationManager>-->
                <!--MS:<asp:ContentPlaceHolder id="PlaceHolderQuickLaunchBottom" runat="server">-->
                    <div class="ms-core-listMenu-verticalBox">
                        <!--SPM:<SharePoint:ClusteredSPLinkButton
                                runat="server"
                                id="idNavLinkViewAll"
                                PermissionsString="ViewFormPages"
                                NavigateUrl="~site/_layouts/15/viewlsts.aspx"
                                Text="&#60;%$Resources:wss,AllSiteContentMore%&#62;"
                                ToolTip="&#60;%$Resources:wss,AllSiteContentMore%&#62;"
                                accesskey="&#60;%$Resources:wss,quiklnch_allcontent_AK%&#62;"
                                CssClass="ms-core-listMenu-item ms-core-listMenu-heading"/>-->
                        <!--PS: Start of READ-ONLY PREVIEW (do not modify)--><a id="ctl00_idNavLinkViewAll" accesskey="3" class="ms-core-listMenu-item ms-core-listMenu-heading" href="#"><span class="ms-splinkbutton-text">All Site Content</span></a><!--PE: End of READ-ONLY PREVIEW-->
                    </div>
                <!--ME:</asp:ContentPlaceHolder>-->
            </div>
            <!--SPM:<SharePoint:DelegateControl runat="server" ControlId="QuickLaunchBottom"/>-->
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderMain" runat="server">-->
            <div>
                <!--CS: Start Page Field: Title Snippet-->
                <!--SPM:<%@Register Tagprefix="PageFieldTextField" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
                <!--SPM:<%@Register Tagprefix="Publishing" Namespace="Microsoft.SharePoint.Publishing.WebControls" Assembly="Microsoft.SharePoint.Publishing, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
                <!--MS:<Publishing:EditModePanel runat="server" CssClass="edit-mode-panel">-->
                    <!--MS:<PageFieldTextField:TextField FieldName="fa564e0f-0c70-4ab9-b863-0177e6ddd247" runat="server">-->
                    <!--ME:</PageFieldTextField:TextField>-->
                <!--ME:</Publishing:EditModePanel>-->
                <!--CE: End Page Field: Title Snippet-->
            </div>
            <div>
                <table>
                <tr>
                    <td colspan="2">
                        <div data-name="WebPartZone">
                        <!--CS: Start Web Part Zone Snippet-->
                        <!--SPM:<%@Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
                        <div xmlns:ie="ie">
                            <!--MS:<WebPartPages:WebPartZone runat="server" AllowPersonalization="false" ID="x7f1e9952cc134a0bb25ed5f4bfb1e985" FrameType="TitleBarOnly" Orientation="Vertical">-->
                                <!--MS:<ZoneTemplate>-->
                                    <!--DC: Replace this comment with default web parts for new pages. -->
                                <!--ME:</ZoneTemplate>-->
                            <!--ME:</WebPartPages:WebPartZone>-->
                        </div>
                        <!--CE: End Web Part Zone Snippet-->
                        </div>
                    </td>
                    <td rowspan="3">
                        <div data-name="WebPartZone">
                        <!--CS: Start Web Part Zone Snippet-->
                        <!--SPM:<%@Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
                        <div xmlns:ie="ie">
                            <!--MS:<WebPartPages:WebPartZone runat="server" AllowPersonalization="false" ID="x83c2929beba040c0996ec15274518824" FrameType="TitleBarOnly" Orientation="Vertical">-->
                                <!--MS:<ZoneTemplate>-->
                                    <!--DC: Replace this comment with default web parts for new pages. -->
                                <!--ME:</ZoneTemplate>-->
                            <!--ME:</WebPartPages:WebPartZone>-->
                        </div>
                        <!--CE: End Web Part Zone Snippet-->
                        </div>
                    </td>
                </tr>
                <tr>
                    <td>
                        <div data-name="WebPartZone">
                            <!--CS: Start Web Part Zone Snippet-->
                            <!--SPM:<%@Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
                            <div xmlns:ie="ie">
                                <!--MS:<WebPartPages:WebPartZone runat="server" AllowPersonalization="false" ID="x96c293f30fe5485e8c3335688c357a4d" FrameType="TitleBarOnly" Orientation="Vertical">-->
                                    <!--MS:<ZoneTemplate>-->
                                        <!--DC: Replace this comment with default web parts for new pages. -->
                                    <!--ME:</ZoneTemplate>-->
                                <!--ME:</WebPartPages:WebPartZone>-->
                            </div>
                            <!--CE: End Web Part Zone Snippet-->
                        </div>
                    </td>
                    <td>
                        <div data-name="WebPartZone">
                        <!--CS: Start Web Part Zone Snippet-->
                        <!--SPM:<%@Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
                        <div xmlns:ie="ie">
                            <!--MS:<WebPartPages:WebPartZone runat="server" AllowPersonalization="false" ID="xdc5816f37d19443c93534987b2e9b98c" FrameType="TitleBarOnly" Orientation="Vertical">-->
                                <!--MS:<ZoneTemplate>-->
                                    <!--DC: Replace this comment with default web parts for new pages. -->
                                <!--ME:</ZoneTemplate>-->
                            <!--ME:</WebPartPages:WebPartZone>-->
                        </div>
                        <!--CE: End Web Part Zone Snippet-->
                        </div>
                    </td>
                </tr>
                <tr>
                <td colspan="2">
                    <div data-name="WebPartZone">
                    <!--CS: Start Web Part Zone Snippet-->
                    <!--SPM:<%@Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
                    <div xmlns:ie="ie">
                        <!--MS:<WebPartPages:WebPartZone runat="server" AllowPersonalization="false" ID="xc6e72151042a475596683e3b21a16dda" FrameType="TitleBarOnly" Orientation="Vertical">-->
                            <!--MS:<ZoneTemplate>-->
                                <!--DC: Replace this comment with default web parts for new pages. -->
                            <!--ME:</ZoneTemplate>-->
                        <!--ME:</WebPartPages:WebPartZone>-->
                    </div>
                    <!--CE: End Web Part Zone Snippet-->
                    </div>
                </td>
                </tr>
                </table>
            </div>
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderFormDigest" runat="server">-->
            <!--SPM:<SharePoint:FormDigest runat="server"/>-->
        <!--ME:</asp:ContentPlaceHolder>-->
        <!--MS:<asp:ContentPlaceHolder id="PlaceHolderBodyAreaClass" runat="server" Visible="true">-->
        <!--ME:</asp:ContentPlaceHolder>-->
    </body>
2
  • just remove all your components and slowly add them back in until you find the one that's duplicating the title. Dec 9, 2016 at 14:00
  • 1
    Or just search for title, check your findings, realize that you added the title placeholder multiple times and remove it.
    – Mx.
    Dec 9, 2016 at 14:37

2 Answers 2

3

Not sure if this is still available. But this is because the following part.

<!--MS:<asp:ContentPlaceHolder id="PlaceHolderPageTitleInTitleArea" runat="server">-->
        <!--SPM:<SharePoint:SPTitleBreadcrumb
                runat="server"
                RenderCurrentNodeAsLink="true"
                SiteMapProvider="SPContentMapProvider"
            CentralAdminSiteMapProvider="SPXmlAdminContentMapProvider"
            SkipLinkText="">-->
        <!--PS: Start of READ-ONLY PREVIEW (do not modify)--><span id="ctl00_DeltaPlaceHolderPageTitleInTitleArea">Home</span><!--PE: End of READ-ONLY PREVIEW-->
        <!--SPM:<PATHSEPARATORTEMPLATE>-->
        <!--SPM:<SharePoint:ClusteredDirectionalSeparatorArrow runat="server"/>-->
        <!--SPM:</PATHSEPARATORTEMPLATE>-->
        <!--SPM:</SharePoint:SPTitleBreadcrumb>-->
        <!--CS: Start Page Field: Title Snippet-->
        <!--SPM:<%@Register Tagprefix="PageFieldFieldValue" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
        <!--MS:<PageFieldFieldValue:FieldValue FieldName="fa564e0f-0c70-4ab9-b863-0177e6ddd247" runat="server">-->
        <!--ME:</PageFieldFieldValue:FieldValue>-->
        <!--CE: End Page Field: Title Snippet-->
    <!--ME:</asp:ContentPlaceHolder>-->

SPTitleBreadCrumb shows the first title in the page as a link. Actually the value is linked to the Name property of this page. The other value is shown because of the PageFieldFieldValue:FieldValue tag which is linked to the Title property. So it's up to you to leave the one you want and remove the other one.

Btw, you didn't do anything wrong. This is by design in the new page layout in SharePoint.

If you don't want to show the link, there is a property in SPTitleBreadcrumb tag which is Visible. You can add this property and value it as false. Then the first link doesn't display on the page anymore.

Hope this helps.

1

Title snippet used twice in above code that's why title displaying twice. Remove anyone of following snippet

1.

  <!--CS: Start Page Field: Title Snippet-->
        <!--SPM:<%@Register Tagprefix="PageFieldFieldValue" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
        <!--MS:<PageFieldFieldValue:FieldValue FieldName="fa564e0f-0c70-4ab9-b863-0177e6ddd247" runat="server">-->
        <!--ME:</PageFieldFieldValue:FieldValue>-->
  <!--CE: End Page Field: Title Snippet-->

2.

    <!--CS: Start Page Field: Title Snippet-->
            <!--SPM:<%@Register Tagprefix="PageFieldTextField" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
            <!--SPM:<%@Register Tagprefix="Publishing" Namespace="Microsoft.SharePoint.Publishing.WebControls" Assembly="Microsoft.SharePoint.Publishing, Version=16.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"%>-->
            <!--MS:<Publishing:EditModePanel runat="server" CssClass="edit-mode-panel">-->
                <!--MS:<PageFieldTextField:TextField FieldName="fa564e0f-0c70-4ab9-b863-0177e6ddd247" runat="server">-->
                <!--ME:</PageFieldTextField:TextField>-->
            <!--ME:</Publishing:EditModePanel>-->
    <!--CE: End Page Field: Title Snippet-->

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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