choose project language via URL

Special forum to share and discuss skins for Pano2VR and Object2VR
Post Reply
dizzz
Posts: 15
Joined: Mon Mar 11, 2019 3:36 pm

Thu Apr 16, 2020 11:06 pm

Hi, I have created a project with GR/ENG versions by using a custom text variable named "language".
Project is working as expected, but I want to be able to access a specific language by URL, (something like test.html?language=gr)
so I don't have to output two times the project to embed on corresponding hosting sites. I 've read that maybe this is done by javascript (define the variable value by URL) but my knowledge stops here. Any help appreciated!

thank you
Dizzz
User avatar
Hopki
Gnome
Posts: 10831
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Sat Apr 18, 2020 10:41 pm

Hi,
Pano2VR has a logic block that can detect Host.
So depending on Host you can then select the default language.
Regards,
Hopki
Garden Gnome Software 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/
dizzz
Posts: 15
Joined: Mon Mar 11, 2019 3:36 pm

Sun Apr 19, 2020 7:40 pm

Hi,

I was expecting something like the example url above (something like test.html?language=gr),
when final project will be delivered, I will not know the exact host name,
I ve tried with the host logic block, but it seems like it detects only the site name, not an included file name or an attribute
Maybe I m not doing something right?

thanks in advance
Dizzz
dizzz
Posts: 15
Joined: Mon Mar 11, 2019 3:36 pm

Tue Apr 21, 2020 12:01 pm

the only partial workaround i ve found is by adding the command pano.setVariableValue to the final html, so I can deliver multiple html files according to the preferred start language.
It's not an ideal solution but it saves me from outputting and uploading multiple times the whole project,
any other suggestions??

thanx
Dizzz
Post Reply