I've started moving to floatbox vs. greybox as it gives more functional ability. Problem is that I get the same issue with both when I change my user agent on my safari - iMac to Mobile Safari - 3.2.2.
I am calling the floatbox via
js(fb.start(client_xml/object_vr/image74.html)). This works in FireFox
3.6.12 - sort of and Safari 5.0.3.
When I switch
my Safari user agent to Mobile Safari 3.2.2 and run the same onclick
statement I get the following errors in my pano1.js file.
Quotekrpano embedding error: there is already a html element with this id: krpanoSWFObject pano1.js:48
&
TypeError: Result of expression 'J[a[_[106]]]' [undefined] is not an object. pano1.js:48
My HTML looks like this.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Optical Trends 4U</title>
<link type="text/css" rel="stylesheet" href="fb/floatbox.css" />
<script type="text/javascript" src="fb/floatbox.js"></script>
<script type="text/javascript" src="fb/options.js"></script>
<meta name="viewport" content="target-densitydpi=device-dpi, width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0" />
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<style>
body{ font-family:Arial, Helvetica, sans-serif; font-size:10px; color:#FFFFFF; background-color:#FFFFFF; margin:0; padding:0; }
* html, * html body{ overflow: hidden; }
a{ color:#AAAAAA; text-decoration:underline; }
a:hover{ color:#FFFFFF; text-decoration:underline; }
</style>
</head>
<body>
<script type="text/javascript" src="pano1.js"></script>
<script type="text/javascript" src="javascript/swfobject.js"></script>
<script type="text/javascript" src="javascript/swfkrpanomousewheel.js"></script>
<div id="krpanoDIV" style="width:100%; height:100%;">
<script type="text/javascript">
// <![CDATA[
if (typeof(deconcept) !== 'undefined')
{
if (deconcept.SWFObjectUtil.getPlayerVersion().major >= 6)
{
var viewer = createPanoViewer({swf:"krpano.swf", id:"krpanoSWFObject", width:"900", height:"550", target:"krpanoDIV"});
//viewer.useHTML5("whenpossible"); // incomment to use the HTML5 krpanoJS viewer always when possible (Safari5)
if( viewer.isDevice("iPhone|iPad|Android") )
viewer.addVariable("xml", "startup_mobile.xml");
else
viewer.addVariable("xml", "startup.xml");
viewer.addParam("allowFullScreen","true");
viewer.addParam("wmode","opaque");
viewer.embed();
if ( viewer.embed("krpanoDIV") ) { var mousewheelfixes = new SWFkrpanoMouseWheel(viewer); }
}
else
{
document.getElementById("krpanoDIV").innerHTML = '<table width="100%" height="100%"><tr valign="middle"><td><center>ERROR:<br><br>Adobe Flash Player 9 needed<br><br><br><a href="http://www.adobe.com/go/getflashplayer/" target="_blank"><IMG SRC="http://www.macromedia.com/images/shared/download_buttons/get_flash_player.gif" BORDER="1"></a><br>...click here to download...<br><br><br><br></center></td></tr></table>';
}
}
else
{
document.getElementById("krpanoDIV").innerHTML = '<table width="100%" height="100%"><tr valign="middle"><td><center>ERROR:<br><br><b>./javascript/swfobject.js</b> not found<br><br><br><br><br></center></td></tr></table>';
}
// ]]>
</script>
</body>
</html>
Display More
My Flash xml looks like this:
<hotspot name="hs10"
url="../plugins/hotspot_ani_white.swf"
keep="false"
ath="167" atv="17"
blendmode="difference"
onhover="showtext(Click to Learn More, csmall);"
onclick="set(fullscreen,false); action(open_cogan,())"
/>
<action name="open_cogan">
js(fb.start(client_xml/object_vr/Image74.swf));
</action>
Display More
My iPad xml looks like this and won't work with an action:
<hotspot name="spot1" style="hotspot_ani_white"
ath="167"
atv="17"
zoom="false"
onclick="js(fb.start(client_xml/object_vr/image74.html));"
/>
It doesn't matter if it is html or an image I get the errors.
Hope someone can help. you can see it at http://www.eyecandyvi.com/tb/fb_mobile.html. Pan to the left and follow the feet to the next pano. Pan again to the left and you'll see the pulsing icon.
Robert