none
Hide a home tab for root site SharePoint 2013 Server

    Question

  • As in title:

    I was wondering if you could help me with my issue as I am not a designer and seem to have some trouble with a simple requirement.
    I need to hide a first home tab in a top nav menu for a site collection root page. It is there, next to a logo which also works as a home site link. I accomplished this in SP2010 adding simple CSS to the default CSS file:

    <style type="text/css">
     .s4-tn li.static > a{ 
    display: none !important; 

    .s4-tn li.static > ul a{ 
    display: block !important; 
    }
     </style>

    In SP2013 Server, in site collection with publishing features activated- it does not work. I edit corev15.css but nothing happens! What should I do? Regards Lukas

    Thursday, July 11, 2013 10:04 AM

All replies

  • Hi Lukas,

    Have a  try to use the JavaScript.

    http://social.technet.microsoft.com/Forums/en-US/78906089-4954-4096-a081-04cc19da162d/sharepoint-home-tab-hiding-in-java-script

    Best Regards.


    Kelly Chen
    TechNet Community Support

    Friday, July 12, 2013 7:25 AM
    Moderator
  • Hi Kelly,

    Thanks for the reply!

    Although javascript works just fine, it is not particularly useful in my scenario. My root site isn't called 'Home'. It is named after the site collection and it is vital that the name of that page stays as it is. This way, users will see a meaningful name of their site (as opposed to 'Home') and the internet browser will also contain the name in the tab which will enhance user experience when switching between IE tabs.

    Furthermore, by hiding a particular word/phrase by injecting javascript into a page we will hide other objects e.g. titles of particular webparts, subjects of discussion posts etc. containing that name...

    Therefore, I cannot rename the page to 'Home' and I cannot hide the existing page name as it will be used throughout the page and cause issues.

    I would definitely go the CSS route. It worked for me in SP2010 Server. For some reason in 2013, they do not want you to edit master pages that easily. Maybe they changed classes too. I do not know, i am not a designer.

    The internet is full of step-by-step guides on how to hide a home tab using CSS in SP2010. I could not find one concerning SP2013.

    Anyone up for the challenge?

    Regards

    EDIT

    I ended up using jquery to hide the text 'Home' on the page. The home tab link disappeared but it is not the ideal solution. How and where can I do it in master page/CSS? 

    • Edited by Lukas_UK Tuesday, November 19, 2013 2:50 PM
    Friday, July 12, 2013 9:51 AM
  • Try this, seems to have resolved the issue for me so far:

    <style type="text/css">
    .ms-core-listMenu-horizontalBox li.static > a{ 
    display: none !important; 
    }
    .ms-core-listMenu-horizontalBox li.static > ul a{ 
    display: block !important; 
    }
    </style>

    Check out my blog: http://thebaretta.blogspot.com.au
    • Edited by Brett Randall - Tuesday, December 10, 2013 11:02 PM adding blog link
    Tuesday, December 10, 2013 11:01 PM
  • Hi Lukas

    please try

    ms-breadcrumb-top li.static > a{ 
    display: none !important; 
    } 
    ms-breadcrumb-top li.static > ul a{ 
    display: block !important; 
    }


    Manoj Gangwar | Sharepoint MCPD | Sharepoint MCTS |

    Wednesday, December 11, 2013 10:21 AM
  • Brett,

    could you give more details about this solution.

    I posted the sam question on your blog, so you can answer there too...

    Regards,

    Srdjan

    Wednesday, February 26, 2014 3:27 PM