Switching languages with langswitcher

Hello,

Grav: 1.7.41.1
Plugin: langswitcher version 3.1.1 (so the 2015 forum post no longer seems relevant)
Theme: Quark derived (deleting the footer and the GRAV logo)
Modular page

I’m building a multiple language site using langswitcher, languages are en and nl (short names).
Pages are generated correctly, URL has /en and /nl showing the correct content.

What I can’t figure out is how to get a menu on screen (maybe in the menu bar on top) where the user can switch the language.

many thanks for your assistance!

Klaas

@KlaasHDec,

What I can’t figure out is how to get a menu on screen (maybe in the menu bar on top) where the user can switch the language

Didn’t the README of the langswitcher plugin answer this question in the Usage section?

Not in a way I understand…

It is the somewhere in “into your own theme somewhere” that confuses me.

Ha.
So maybe add

{% include 'partials/langswitcher.html.twig' %}
{% include 'partials/langswitcher.hreflang.html.twig' %}

somewhere else perhaps.

Let’s try partials/base.html.twig …

That does give me a switch.

Now to get it in the menu and get to it work…

Thanks for the nudge.
Not yet completely solved but getting there.

Klaas

Almost. Putting the % includes in the navbar section of partials/base.html.twig

I have the option to switch from /nl to /en, but the /en page does not have the menu to switch back to nl

I have to get rid of the
{% include ‘partials/langswitcher.hreflang.html.twig’ %}

Not sure yet I know why.
Maybe counts as solved anyway.

… almost

I have modified the partials/base.html navbar sectionto show the language selector and deleted the bit with the Grav logo.

So in English, I get the language selection menu without the Grav logo.
In nl, I get the language section menu with the Grav logo.

Any nudging is still most welcom.

Klaas