I am using Safari 5+ to view this sample.
If the user agent is Windows or Mac it works (uses flash).
If the user agent is iPad (etc.) it fails.
Has anyone else come accross this?
It is not my intent to use setTimeout but there is a delay in my code and it's acting the same.
Code
<script type="text/javascript" src="/swf/jquery.js"></script>
<script type="text/javascript" src="/swf/swfkrpano.js"></script>
<script type="text/javascript">
<!--
var viewer = {};
$(window).ready(function() {
viewer = createPanoViewer({
swf:"/swf/krpano.swf",
id: "embed-player",
target: "gallery-main-player"
});
var _xml = "/swf/examples/xml-usage/compass/compass.xml";
if (viewer.isDevice("iPhone|iPod|iPad|Android")) {
_xml = "/swf/examples/xml-usage/compass/compass.xml"; // Obviously these are different in production
} else {
viewer.addParam("wmode","transparent");
}
viewer.addVariable("xml", _xml);
});
///*** This breaks HTML5 ***///
setTimeout(function() { viewer.embed(); }, 2000);
//-->
</script>
<div id="gallery-main-player"></div>
Alles anzeigen
Thanks,
Jon