2

I have a requirement to change the Top bar titles for my team site and community site. For example I need to change the “Page” to be “Page options”.so from where I can change these titles.? Second question I have three different types of lists inside my team site, and each list have a Page tab, so can I change the title per list, or I only can do this for the whole site. As inside the document management library I want the Page to be “Document library options”, and for the announcement list I want it to be “Announcement Options “instead of being “Page” for both.

enter image description here

EDIT I have created the following script insde my Style library folder:-

$(document).ready(function(){$("#Ribbon\\.WebPartPage-title span").first().html('PAGE OPTIONS');
$('.ms-cui-tts').click(function() {
    $('#Ribbon\\.WebPartPage-title span').first().html('PAGE OPTIONS');
 });
$('#Ribbon\\.WebPartPage-title a').click(function() {
        $('#Ribbon\\.WebPartPage-title span').first().html('PAGE OPTIONS');});
 });

then i reference the script inside my master page as follow , before the tag :-

<script  type="text/javascript" src="/sites/Intranet/Style Library/JS/changetitles.js" ></script>

</head>

But it did not chnage the title ?

4
  • 1
    Are you referencing a js that is in other site collection? Maybe there is the problem /sites/Intranet/Style Library/JS/changetitles.js. If you are in the same site collection just use src="/Style Library/JS/changetitles.js"
    – Alvmad
    Sep 25, 2013 at 10:50
  • No it is on the same site collection, anyway i chnage it to "/Style Library/JS/changetitles.js" but stil the page title did not change, baring in mind that i have other scripts on the same Js folder and i am calling them on the same way and they are working well? not sure what is going on ?
    – John John
    Sep 25, 2013 at 12:00
  • Could you open Firebug with firefox and put a breakpoint on the .js in the next line after $(document).ready(function() ant check if it stops there?
    – Alvmad
    Sep 25, 2013 at 13:01
  • Did you resolve your issue with my solution? If not, post the solution please.
    – Alvmad
    Sep 25, 2013 at 17:28

1 Answer 1

1

you can achieve this by adding this code into your .js file

$("#Ribbon\\.WebPartPage-title span").html('PAGE OPTIONS');

I don't understand the second question. For document libraries the option is "LIBRARY" not "PAGE". And for custom lists the option tab is LIST. Can you update your post with a screen capture of those options in your custom lists?

UPDATED

Try this. It worked for me. This is the best approach I can give you right now

$(document).ready(function(){$("#Ribbon\\.WebPartPage-title span").first().html('PAGE OPTIONS');
$('.ms-cui-tts').click(function() {
    $('#Ribbon\\.WebPartPage-title span').first().html('PAGE OPTIONS');
 });
$('#Ribbon\\.WebPartPage-title a').click(function() {
        $('#Ribbon\\.WebPartPage-title span').first().html('PAGE OPTIONS');});
 });

enter image description here

I got working putting that code in my js before ending </head>

<script type="text/javascript" src="/Style Library/js/navigation.js"></script>
12
  • thanks for the reply, so i need to create a custom JS file inside my style library ? and then write all the renaming ?
    – John John
    Sep 24, 2013 at 8:34
  • Yes it would be an approach. Or if you already have custom .js files you could put your code there with <!-- Tab Personalization Section -->
    – Alvmad
    Sep 24, 2013 at 8:38
  • i have added the following Script <script type= "application/javascript"> $("#Ribbon\\.WebPartPage-title span").html('PAGE OPTIONS'); </script> at the end of my master page ,, but it did not change the Page to "Page Options" ? any advice please
    – John John
    Sep 24, 2013 at 12:10
  • 1
    Adding this reference PAGE literal has been changed by PAGE OPTIONS? I will tell you how to changue the others
    – Alvmad
    Sep 24, 2013 at 15:45
  • 1
    Read the updated answer please
    – Alvmad
    Sep 24, 2013 at 18:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.