Under the personal action menu, there are two links :
- My site
- My profile
I'm trying to understand how they are generated and by which component/feature. However the highest container in the control hierarchy I was able to discover is the FeatureMenuTemplate control, within PersonalActions control (itself in the welcome.ascx control).
If I replace the Welcome.ascx by a custom one with this minimal content :
<%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Import Namespace="Microsoft.SharePoint" %> <%@ Assembly Name="Microsoft.Web.CommandUI, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Control Language="C#" Inherits="Microsoft.SharePoint.WebControls.Welcome,Microsoft.SharePoint,Version=14.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c" AutoEventWireup="false" compilationMode="Always" %>
<SharePoint:PersonalActions accesskey="<%$Resources:wss,personalactions_menu_ak%>" ToolTip="<%$Resources:wss,open_menu%>" runat="server" id="ExplicitLogout" Visible="false">
<CustomTemplate>
<SharePoint:FeatureMenuTemplate runat="server"
FeatureScope="None"
Location="Microsoft.SharePoint.StandardMenu"
GroupId="PersonalActions"
id="ID_PersonalActionMenu"
UseShortId="true"
>
<SharePoint:MenuItemTemplate runat="server" id="ID_LoginAsDifferentUser"
Text="<%$Resources:wss,personalactions_loginasdifferentuser%>"
Description="<%$Resources:wss,personalactions_loginasdifferentuserdescription%>"
MenuGroupId="200"
Sequence="100"
UseShortId="true"
/>
</SharePoint:FeatureMenuTemplate>
</CustomTemplate>
</SharePoint:PersonalActions>
<SharePoint:ApplicationPageLink runat="server" id="ExplicitLogin"
ApplicationPageFileName="Authenticate.aspx" AppendCurrentPageUrl="true"
Text="<%$Resources:wss,login_pagetitle%>" style="display:none" Visible="false" />
This works, but there are still the two links mentionned before.
I tried to dive with reflector to understand how these links are generated. I tried to find any custom action. No success.
What is causing this two links to appear ?
PS: my actual goal is to remve this links, I found some workaround on the web but I'm still looking for an explanation, for my personal comprehension (and sanity)