• Resolved luqman305

    (@luqman305)


    Hi.

    I love your plugin. But may I know is it possible for me to use your language switcher inside my custom html

      tags? Any help and guide will be much appreciated.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Cristian Antohe

    (@sareiodata)

    Hi,

    You would need to extend the \wp-content\plugins\translatepress\includes\class-language-switcher.php class, then change the template found inside \wp-content\plugins\translatepress\partials\language-switcher-shortcode.php

    The language_switcher() function is responsible for the generation of all languages, but you’ll need to overwrite this in the extended class, so you don’t include the same template.

    It can be done via a custom plugin, without making changes to the main plugin, however, it’s beyond what we can offer via our support.
    You can use

    $trp_clone = TRP_Translate_Press->get_trp_instance();

    And go from there.

Viewing 1 replies (of 1 total)
  • The topic ‘Add translatepress language on custom HTML’ is closed to new replies.