WordPress.org

Support

Support » Plugins and Hacks » Multisite Language Switcher » [Resolved] [Plugin: Multisite Language Switcher] flags in Hatch theme menu

[Resolved] [Plugin: Multisite Language Switcher] flags in Hatch theme menu

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Dennis Ploetner

    @realloc

    You could try to add some code in the functions.php of your theme. Please have a look here -> “Manipulate the Navigation Menu” at https://github.com/lloc/Multisite-Language-Switcher/wiki/Generate-the-output

    Cheers,
    Dennis.

    Great ! Thank you, it worked like a charm 🙂

    Marking as resolved

    Hi!

    I’ve found this post very useful as I had the same problem as Polypa.

    I have one more question : how is possible to show the desciption on the language near the flag??

    And, I’ve inserted the code…

    ———————–

    function my_custom_menu_item( $items, $args ) {
    if ( class_exists( ‘MslsOutput’ ) && ‘primary’ == $args->theme_location ) {
    $obj = new MslsOutput;
    $arr = $obj->get( 2 );
    if ( !empty( $arr ) ) {
    $items .= ‘

  • ‘ . implode( ‘
  • ‘, $arr ) . ‘
  • ‘;
    }
    }
    return $items;
    }
    add_filter( ‘wp_nav_menu_items’, ‘my_custom_menu_item’, 10, 2 );

    ——————–

    …quite randomly in the function.php page under the section //SIDEBAR. It is ok or I’ve to copy it in a proper position??

    Sorry I’m just beginner!

    thanks for the support!

    Giorgio

    http://www.gioinviaggio.com

Plugin Author Dennis Ploetner

@realloc

No problem! For the first question: Please have a look here!

first of all thanks! I’ve tryed copy both the codes together but nothing happened. Insead now the flag isn’t centered, but set on top of the menu.

http://www.gioinviaggio.com

Can you give a look?

Exactly where I have to place these/that code/codes in the function.php??

many thanks again for the support!

Giorgio

Plugin Author Dennis Ploetner

@realloc

Seems that your html needs li-tags … 😉

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Resolved] [Plugin: Multisite Language Switcher] flags in Hatch theme menu’ is closed to new replies.
Skip to toolbar