Unclickable Page Title in Team Site SharePoint 2013

I got the below question on SE community.

questHow to Remove Home Page Title URL to be unclickable in Teamsite SharePoint 2013?

remove-page-title-link-in-sharepoint-2013-team-site

In this hint, I’m gonna to answer this question in detail by following the below steps:

Steps:

  • Edit your Page by clicking on the right corner gear icon.

Edit Page

  • At the end of your content (in my case, below the image) > Set the mouse to show the page ribbon.
  • From the above ribbon > click on insert Tab > Web Part.

Add web part at team site page.gif

  • At Media and Content Category > Select Script Editor > Click on Add.

script-editor-at-team-site

  • Now you will note that you are Missing EDIT SNIPPET option in Script Editor and to show it.
    • Just click on the arrow at the right corner of the Script Editor > Select Edit Web Part > then Click Ok without any changes.edit-web-part
  • Now the Edit Snippet Should be shown.

missing-edit-snippet-at-script-editor

  • Click On Edit Snippet > add the below Script with your Page Title at var searchText = "QassasHome"; 

<script type="text/javascript>
function disablelinkPageTitle() {
var aTags = document.getElementsByTagName("a");
var searchText = "QassasHome"; // set your page title
var link;
for (var i = 0; i &lt; aTags.length; i++) 
{
if (aTags[i].textContent == searchText) 
{
link = aTags[i];
link.href="#"; //remove URL
link.style.cursor = 'default'; // Change mouse&nbsp;cursor
break;
}
}
}
_spBodyOnLoadFunctionNames.push("disablelinkPageTitle"); 
</script>

  • Save your Page > try to click on the Home Page title, this should be now unclickable as shown below.

unclickable-page-title-in-team-site-page Enjoy 🙂

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s