Custom menu with gtranslate function

Popular automatic website translation tool

Custom menu with gtranslate function

Postby luqman305 » Tue Dec 04, 2018 3:14 am

I am very newbie with wordpress and editing plugins.

I have custom menu (English, Chinese (Simplified)) using html that I want it to call the gtranslate function for each language but it seems like it does not working. I dont know how to run the gtranslate with my custom menu.please help.

HTML codes:
Code: Select all
<li class="li-eng"><i class="sl-flag flag-usa"><div id="usa"></div></i> <span class="active"><?php _e('English', 'gtranslate'); ?></span></li>
<li class="li-zh"><i class="sl-flag flag-de"><div id="chinese"></div></i> <span><?php _e('Chinese (Simplified)', 'gtranslate'); ?></span></li>
Posts: 1
Joined: Tue Dec 04, 2018 3:08 am

Re: Custom menu with gtranslate function

Postby Yana » Tue Dec 04, 2018 6:41 pm

If you wish to add GTranslate in menu you can also use Shortcode in Menus plugin with [gtranslate] shortcode.

Install Shortcode in Menus plugin from Wordpress repository (Plugins → Add new and search for Shortcode in Menus)
Go to Appearance → Menus and on the left part you will see Shortcodes
Put [gtranslate] shortcode in it and add to menu
Set Show in menu option to None in GTranslate settings page

Yana Ghahramanyan - GTranslate Team

Please leave your feedback on your CMS plugin directory. It is very important for us!
Google Translate Joomla
Google Translate WordPress
Google Translate Drupal
Posts: 4547
Joined: Thu Jan 12, 2012 2:21 pm

  • Related Topics
    Last post

Who is online

Users browsing this forum: No registered users and 1 guest