Please help in building a multilingual interface

  • Hi!

    Change language by pressing the (flag):

    Code
    onclick="set(currentlanguage, russian);
    onclick="set(currentlanguage, english);


    Names panoramas, hotspots and descriptions in a separate file.
    Example, text_data_en.xml:

    Displays the name of the current scene:

    Code
    txtadd(layer[skin_scene_title].html, get(language[get(currentlanguage)].text[main_title].value), '[br]', get(language[get(currentlanguage)].text[get(xml.scene)].sc_title) ); , 
    copy(layer[skin_scene_title].html, language[get(currentlanguage)].text[get(xml.scene)].sc_title );


    It works.

    Name hotspot:

    Code
    onhover="if(skin_settings.tooltips_hotspots, if(linkedscene, showtext(get(language[get(currentlanguage)].text[get(linkedscene)].sc_title),SKIN_TOOLTIPS)) );"


    It works too.

    Function skin_addmapspots():

    Code
    ...
    if(skin_settings.tooltips_mapspots, 
    escape(spottitle,get(language[get(currentlanguage)].text[get(scene[get(i)].name)].sc_title)); 
    txtadd(spothoverevent,'showtext(',get(spottitle),',SKIN_TOOLTIPS)'); , set(spothoverevent,null); 
    				);
    addspot(get(spotname), get(scene[get(i)].lat), get(scene[get(i)].lng), get(scene[get(i)].heading), false, get(spotclickevent), get(spothoverevent));
    ...

    get(language[get(currentlanguage)].text[get(scene[get(i)].name)].sc_title)
    Displays the name of the mapspot only on default language. Language select dont work.


    As I understand it, the call skin_addmapspots(); occurs only once. By event onmapready.

    I tried to call this function when changing the language:

    Code
    onclick="set(currentlanguage, russian); skin_addmapspots();
    onclick="set(currentlanguage, english); skin_addmapspots();


    It did not work Mapspot signed only on the default language.


    What do I need to change the language of signatures mapspot?

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!