Description in two different languages   [SOLVED] - View the solution

Share your tips and tricks here or get help with any Panotour 2.0+ problem!
No bug reports (of any kind) in this forum!
no avatar
Krisztina Imre
Member
 
Topic author
Posts: 124
Likes: 0 post
Liked in: 0 post
Joined: Fri Jun 21, 2013 9:11 am
Location: Hungary
Info

Description in two different languages

by Krisztina Imre » Sat Sep 20, 2014 4:52 pm

Any ideas? I need to make a virtual tour, where the descriptions are in two languages. (first a simple html with flags that links to appropriate tour) Can I make this without to make two separate virtual tour?

no avatar
benji33
Kolor Team
 
Posts: 5848
Likes: 92 posts
Liked in: 199 posts
Joined: Tue Apr 09, 2013 10:59 am
Location: France
Info

Re: Description in two different languages  [SOLVED]

by benji33 » Mon Sep 22, 2014 10:25 am

Add into yourtour_messages_en.xml file the new tags (copy all tags, rename them and translate them) for the other language.

For instance
Code: Select all
<data name="en_panotourmapsmap_title">Map</data>
<data name="nl_panotourmapsmap_title">Kaart</data>


Then add a toggle button plugin with a default action to apply later a select language code.

On this new button into yourtour_skin.xml file apply this code on the togglebuttonOnClick action where togglebutton is the name of the button :
<action name="togglebuttonOnClick">
if (state,
set(state, false);setDutch();
set(url,%FIRSTXML%/graphics/togglebutton/english_flag.jpg);
,
set(state, true);setEnglish();
set(url,%FIRSTXML%/graphics/togglebutton/dutch_flag.jpg);
);
</action>

Then add these 2 actions into the xml :
<action name="setDutch">set(tour_language, nl);</action>
<action name="setEnglish">set(tour_language, en);</action>

On next refresh of the description plugin, the description will be updated.

At this time there is no way to refresh the data already displayed.
Benjamin

no avatar
Krisztina Imre
Member
 
Topic author
Posts: 124
Likes: 0 post
Liked in: 0 post
Joined: Fri Jun 21, 2013 9:11 am
Location: Hungary
Info

Re: Description in two different languages

by Krisztina Imre » Tue Sep 23, 2014 5:35 pm

benji33 wrote:Add into yourtour_messages_en.xml file the new tags (copy all tags, rename them and translate them) for the other language.

For instance
Code: Select all
<data name="en_panotourmapsmap_title">Map</data>
<data name="nl_panotourmapsmap_title">Kaart</data>


Thanks, I will try this! :)

no avatar
thomash
Member
 
Posts: 24
Likes: 0 post
Liked in: 0 post
Joined: Wed Feb 10, 2010 7:28 pm
Info

Re: Description in two different languages

by thomash » Tue Sep 23, 2014 8:39 pm

benji33 wrote:Add into yourtour_messages_en.xml file the new tags (copy all tags, rename them and translate them) for the other language...
On next refresh of the description plugin, the description will be updated. At this time there is no way to refresh the data already displayed.

Do you have an example tour of multiple languages that I could check out?
Could you please explain "refresh" and how this affects the switch in languages?
Do the onClick actions instantly change the sidebar pano titles/thumbnail captions?
Thanks

no avatar
thomash
Member
 
Posts: 24
Likes: 0 post
Liked in: 0 post
Joined: Wed Feb 10, 2010 7:28 pm
Info

Re: Description in two different languages

by thomash » Tue Sep 23, 2014 8:43 pm

Also, is it possible to play different Livepano videos in different languages depending on the language flag?

no avatar
benji33
Kolor Team
 
Posts: 5848
Likes: 92 posts
Liked in: 199 posts
Joined: Tue Apr 09, 2013 10:59 am
Location: France
Info

Re: Description in two different languages

by benji33 » Wed Sep 24, 2014 8:12 am

No at this time the refresh is not done on most of the HTML5 components and on some plugins.
Need to change the active panorama to refresh.

Not yet for videos.

Language support is a trick not a full functionnality at this time.
Benjamin

no avatar
thomash
Member
 
Posts: 24
Likes: 0 post
Liked in: 0 post
Joined: Wed Feb 10, 2010 7:28 pm
Info

Re: Description in two different languages

by thomash » Wed Sep 24, 2014 10:49 am


no avatar
benji33
Kolor Team
 
Posts: 5848
Likes: 92 posts
Liked in: 199 posts
Joined: Tue Apr 09, 2013 10:59 am
Location: France
Info

Re: Description in two different languages

by benji33 » Wed Sep 24, 2014 12:28 pm

Yes their make great tours.
It's a full HTML5/JS interface over a krpano engine.
So the language refresh is binded on JS "plugins".

Panotour will do the same on a refresh event once language will be fully implemented. It's not the case at this time.
Benjamin


Who is online

Users browsing this forum: No registered users and 4 guests

cron