Customer request to set default language in URL

Special forum to share and discuss skins for Pano2VR and Object2VR
Post Reply
User avatar
EVerheggen
Posts: 65
Joined: Wed Feb 05, 2020 12:16 pm
Location: Netherlands
Contact:

Hi,

For my client I made a one language tour in Dutch, some time ago.

Now I added a second language, English in the last update of the tour: https://www.360-bedrijfspresentatie.nl/ ... 023-02-09/

Since the original tour language is Dutch, my (Dutch) client (with a browser in Dutch) sees the Dutch version, even on their English pages. The question is to set the default tour language to English by adding &lang=en to the URL (or something similar).

One solution I can make myself is to change the tour language to English after config loaded. But that would mean that the client has two versions of the tour.

An other solution would be to swap all texts and have English as primary language. But that is too much work....

Is there a way to choose the starting language with some additional characters in the URL?

Best regards,

Erik Verheggen
User avatar
Hopki
Gnome
Posts: 13025
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi Erik,
You can use a query.
Please see the attached project.

It has a text variable called lang, the query sets the variable value.
The code element has a Config Loaded then using Expert mode uses the variable placeholder.
So when you add either de or en at the end the tour will open using that language.

End the URL with
?lang=de

or

?lang=en

Regards,
Attachments
query.zip
(644.18 KiB) Downloaded 80 times
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
User avatar
EVerheggen
Posts: 65
Joined: Wed Feb 05, 2020 12:16 pm
Location: Netherlands
Contact:

Thank you very much for yet another quick reply Martin!

I am going to try this right now.
User avatar
EVerheggen
Posts: 65
Joined: Wed Feb 05, 2020 12:16 pm
Location: Netherlands
Contact:

It works! Thank you Martin!

This is the result:

Start in English: https://www.360-bedrijfspresentatie.nl/ ... l?lang=en/

Start in Dutch: https://www.360-bedrijfspresentatie.nl/ ... ml?lang=nl
Post Reply