Article Categories
Archives
Post Categories
  Jump to Information for:
Search:  

Quickly hide the “My Site” link in Portal by adding this style rule to your custom style sheet:

#hlMySite  {display: none}

This changes the display to none, so you aren't actually removing the link from the code.

posted on Monday, October 03, 2005 6:31 PM
Comments
  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    Nic
    Posted @ 10/9/2005 10:14 AM
    Do you have a method for this to work in WSS
  • # SharePoint Design Tip: Secret to my CSS Trickery
    Heather Solomon - MVP, WSS - Blo
    Posted @ 10/11/2005 9:18 PM
  • # re: SharePoint Usability Tip: Hide the My Site link in Portal
    Heather
    Posted @ 10/11/2005 8:20 PM
    Well there isn't My Site in WSS, but if you mean another link, not really. WSS gets finicky and changes out the IDs assigned to href tags, so the CSS trickery doesn't work the same. You can however edit the links in the ONET.XML file.
  • # re: SharePoint Usability Tip: Hide the My Site link in Portal
    Jeremy
    Posted @ 2/28/2007 3:32 PM
    Nic,

    maybe heather will email this to you.

    The links you're referring to in the Top Navigation bar on a WSS site are very easy to find in the DOM. (even if you don't know their IDs)

    They're all located inside of a TD element with an ID of HBN100 and have the following URLs.

    http://sharepoint/sites/<SITENAME>/default.aspx
    http://sharepoint/sites/<SITENAME>/_layouts/1033/viewlsts.aspx
    http://sharepoint/sites/<SITENAME>/_layouts/1033/create.aspx
    http://sharepoint/sites/<SITENAME>/_layouts/1033/settings.aspx
    javascript:HelpWindowKey("NavBarHelpHome")

    I'm of course referring to Home, Documents and Lists, Create, Site Settings and Help.

    Place a content editor part on your page, hide the title bar, give it a good name, like "RemoveNavBarLinks", and then open the View Source.

    You should end up with the following code more or less.

    <script type="text/javascript">
    badurlregExps = { /url1pattern/, /url2pattern/ }
    navbar = document.getelementbyid('HBN100');
    links = navbar.getelementsbytag("A");

    for(i=0; i<links.length-1; i++)
    {
    for(j=0; j<badurlregexps.length-1;j++)
    {
    if(badurlregexps[j].test(links[i].href)
    {
    // a match
    toggleelement(links[i]);
    }
    else
    {
    // no match - log something?
    }

    }
    }
    </script>
  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    Alison
    Posted @ 4/9/2007 2:10 PM
    I am not having any lucK with this. Our portal site is using the "Classic" theme. I have set the Master Page to use my Custom style sheet (which only has this one entry). I am not a programmer - I lost my coder to another project - so all this is new to me. Should I copy the contents of the Classic CSS to my custom CSS and get rid of theme? Any help would be greatly appreciated.

    Thanks.
  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    Marees
    Posted @ 4/23/2007 4:06 AM
    Tricky.

    Very useful. Thanks a lot
  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    David
    Posted @ 5/25/2007 4:26 AM
    I don't know if anyone has another work around but the original css rule didn't work for me. I discovered that the id was ctl00_PlaceHolderGlobalNavigation_ctl08_hlMySite in my site. when I put #ctl00_PlaceHolderGlobalNavigation_ctl08_hlMySite{dispay:none} it worked!! Another designer in my company had a similiar problem with referencing controls that sit in master pages and used classes in his css instead of referencing by id. Is there any way around this?
    I guess there won't be as the browser renders the control id as ctl00_PlaceHolderGlobalNavigation_ctl08_hlMySite and it needs to be referenced as this. The most obvious problem is when PlaceHolderGlobalNavigation changes name then all references are broken
  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    jordan
    Posted @ 6/12/2007 3:24 AM
    fucking shit im no ganen on this site ever again
  • # re: SharePoint Usability Tip: Hide the My Site link in Portal
    Magnus
    Posted @ 8/9/2007 6:05 AM
    As ever you are the "font" of knowledge on sharepoint..


    Thanks this gets me round allowing users to add alerts without the confusion of explainnig My Site to 800 users

  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    Jeremy
    Posted @ 12/6/2007 4:03 PM
    Removing this line from the HTML works too.

    <SharePoint:DelegateControl ControlId="GlobalSiteLink2" Scope="Farm" runat="server"/>

  • # re: SharePoint Usability Tip: Hide the My Site link in Portal
    marc
    Posted @ 4/8/2008 3:45 AM
    You can also deactive it with:

    stsadm -o deactivatefeature -name MySite
  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    djs
    Posted @ 5/16/2008 9:37 AM
    You can also control who has the ability to create a MySite (and see the link) using security settings. This setting is in the "Personalization and Services Permissions" link on the SSP home page. I am too lazy to go in to all the details here but it is well documented in the "office sharepoint server 2007 administrator's companion", page 255. This also allows you to turn the link on and off for specific groups of people.
  •  re: SharePoint Usability Tip: Hide the My Site link in Portal
    Daniel
    Posted @ 11/10/2008 7:20 AM
    How can I remove the My Home link in My site? I want that users enter to My profile page only. Any ideas?
Title  
Name  
Email (never displayed)
Url
Comments   
ALL COMMENTS ARE MODERATED! Sorry for the inconvenience, but it is how I keep all of the spam and advertisers out. I moderate comments about once a week and your comment will appear soon. Thanks for posting!
Please add 4 and 7 and type the answer here:

Copyright © 2005-2008. Heather Solomon.
Site design by Heather Solomon

Blog Stats:
Posts - 377
Stories - 38
Comments - 1556
Trackbacks - 182