The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

How to personalize my toolbar

View previous topic View next topic Go down

Solved How to personalize my toolbar

Post by sunshine_222 on January 10th 2015, 7:48 pm

How to personalize my toolbar?
https://i59.servimg.com/u/f59/18/21/41/30/captur47.png

Is it possible to give me a script to change the titles: share/welcome/notifications
in other language? I didn't find these titles in the scripts.


Last edited by sunshine_222 on January 11th 2015, 12:01 pm; edited 1 time in total

sunshine_222
Forumember

Posts : 99
Reputation : 3
Language : english

http://thaimagic.forum2x2.eu

Back to top Go down

Solved Re: How to personalize my toolbar

Post by Ange Tuteur on January 11th 2015, 12:11 am

Hello @sunshine_222,

Go to Administration panel > Modules > JavaScript codes management > Create a new script

Title : your choice
Placement : in the homepage
Code:
$(function() {
  // textual translation of fa_toolbar
  var $lang = {
    welcome : Welcome text',
    notifications : 'Notification text',
    share : 'Share text',
   
    view_profil : 'View profile text',
    watched : 'My watched topics text',
    priv_msg : 'My private message text',
    logout : 'Logout text'
  };
 
  $(function() {
    // logged in content
    if (_userdata.session_logged_in) {
      // fa_right
      $('#fa_welcome').text($lang.welcome + ' ' + _userdata.username);
      $('#fa_notifications').html($lang.notifications + '<span id="notif_unread"></span>');
     
      // fa_menulist
      $('#fa_menulist li:eq(0) a').text($lang.view_profil);
      $('#fa_menulist li:eq(5) a').text($lang.watched);
      $('#fa_menulist li:eq(6) a').text($lang.priv_msg);
      $('#fa_menulist li:last a').text($lang.logout);
    }
   
    // global content
    $('#fa_share_text').text($lang.share);
  });
});

At the top of the script you'll see this :
Code:
 var $lang = {
    welcome : 'Welcome text',
    notifications : 'Notification text',
    share : 'Share text',
   
    view_profil : 'View profile text',
    watched : 'My watched topics text',
    priv_msg : 'My private message text',
    logout : 'Logout text'
  };

Here you can translate the text to what you want.

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: How to personalize my toolbar

Post by sunshine_222 on January 11th 2015, 11:59 am

Thank you, Ange Tuteur! sunny

sunshine_222
Forumember

Posts : 99
Reputation : 3
Language : english

http://thaimagic.forum2x2.eu

Back to top Go down

Solved Re: How to personalize my toolbar

Post by Ramdaman on January 11th 2015, 1:27 pm

Topic solved and archived.

Ramdaman
Active Poster

Male Posts : 1614
Reputation : 97
Language : English, Albanian, Macedonian, Russian | HTML, CSS
Location : New York City

http://ndihme.forumotion.com/forum

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum