External html button to load a new scene

  • Hello,

    I cant get a html button in de layout of my website to changes the scene in the xml of a panotour?


    html

    Code
    <button id="button" onclick="javascript:krpano().call('loadscene(video_scene2)')" type="button">Click Me!</button>


    javascript

    Code
    function krpano(){  return document.getElementById('krpanoSWFObject'); }
    embedpano({swf:"../plugins/krpano.swf", xml:"krpano2.xml", target:"pano", html5:"prefer", passQueryParameters:true});




    What am i doing wrong?

  • try this

    Code
    embedpano({ swf: "krpano.swf", xml: "krpano.xml", id: "krObject", target: "pano", html5: "auto", mobilescale: 1.0, passQueryParameters: true });
    Code
    pano_object = dociment.getElementById('krObject');
    Code
    pano_object.call("loadscene('sceneName',null,MERGE,ZOOMBLEND(1,2,'easeInOutSine'));");

Participate now!

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