A specific custom web part is being instantiated twice on a certain page layout, even if it’s only declared once on the page layout.
Declaration like this:
<%@ Register tagprefix="MyQuickLinks" namespace="Client.Intranet.MyLinksWebPart.MyLinks" assembly="Client.Intranet.MyLinksWebPart, Version=1.0.0.0, Culture=neutral, PublicKeyToken=xxxxxxxxxxxxxxx" %>
<WebPartPages:webpartzone runat="server" Title="Web Part Content" ID="WebPartContent">
<ZoneTemplate>
<MyQuickLinks:MyLinks ID="MyLinks" Title = "My quicklinks" runat="server"/>
</ZoneTemplate>
</WebPartPages:webpartzone>
Creating a new page based on page layout shows web part is rendered/displayed twice.
HTML getting rendered like this--
The first one always:
<DIV id="WebPartctl00_m_MyLinks" class="ms-WPBody noindex ms-wpContentDivSpace" allowDelete="false" width="100%" HasPers="false" WebPartID="00000000-0000-0000-0000-000000000000" allowExport="false">
*web part ID being all zeroes is strange, cause unknown
The second one always:
<DIV id="WebPartctl00_m_g_e825e9c9_f070_4ea3_8231_dfda8fbe90a6" class="ms-WPBody noindex ms-wpContentDivSpace" allowDelete="false" width="100%" HasPers="false" WebPartID="657a284d-7048-4713-b792-7a792fe507ad" allowExport="false">
On Edit mode, the first web part cannot be removed and does not show in ‘Open page in web part maintenance’ mode, as if it were not contained in a web part zone
The second one, can be removed like any normal web part
Can no longer add a new web part of the same type to the same page.
Other page layouts that have the exact same web part declaration do not see this issue, and web parts are instantiated only once, and are able to add the same type of web part to the same page several times without error
This is a new SP2010 built from clean/vanilla stand-alone VM.
Please help