You are not logged in.

1

Tuesday, March 8th 2011, 9:15am

what's the problem in IE

I follow the example code of Javascript interface to make a list pano
there is five lists, click on each one ,the beneath div can show different pano, they all work well in firefox ,but in IE, they are all invalid, include the a:hover is not working, what's the problem, it confusses me much time! *confused*

Source code

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>index</title>
<script type="text/javascript">
function krpano()
{return document.getElementById("krpanoSWFObject")}
function loadpano1()
{
	krpano().call("loadpano('%SWFPATH%/1.xml')")
	}
function loadpano2()
{krpano().call("loadpano('%SWFPATH%/2.xml')")}
function loadpano3()
{krpano().call("loadpano('%SWFPATH%/3.xml')")}
function loadpano4()
{krpano().call("loadpano('%SWFPATH%/4.xml')")}
function loadpano5()
{krpano().call("loadpano('%SWFPATH%/5.xml')")}
</script>
<style type="text/css">
body {
	text-align: center;
	text-align: -moz-center;}
.mainbox {
	background-color: #F0F0F0;
	border: 2px solid #F00;
	width: 1200px;
	margin: 20px auto 0px;
}
ul {
	list-style-type: none;
	font-size: 24px;
	font-weight: bolder;	
	color: #666;
	padding:0px;
	margin: 0px;}
ul li {
	float: left;
	margin-left: 30px;
	background-color:#84E276;}
#krpanoSWFObject{
	text-align:center;
	margin-top:40px;
	border:1px solid #00f;
	padding:0px;}
li a{
	cursor:pointer;}
li a:hover{
	color:white;
	background-color:#960;}
</style>
</head>
<body>
<div class="mainbox">
<div id="menu">
<ul style="margin-left:0px;">
<li style="margin-left:0px;"><a onclick="loadpano1()">pano1</a></li>
<li><a onclick="loadpano2()">pano2</a></li>
<li><a onclick="loadpano3()">pano3</a></li>
<li><a onclick="loadpano4()">pano4</a></li>
<li><a onclick="loadpano5()">pano5</a></li>
</ul></div>
<div id="krpano"><embed src="1.swf" width="1200" height="640" id="krpanoSWFObject" flashvars="pano=1.xml"></embed></div>
</div>
</body>
</html>

2

Thursday, March 10th 2011, 2:09pm

Hi,

the IE needs an <object> tag for embedding the Flashplayer,
but I would recommed embedding krpano via Javascript,

see here:
http://krpano.com/docu/swfkrpanojs/
http://krpano.com/docu/html/#withoutjavascript

best regards,
Klaus

3

Friday, March 11th 2011, 7:52am

Hi,

I would like to know if above coding support Ipad/Iphone?


Thanks,
Minkey.

4

Friday, March 11th 2011, 8:45am

Hi,

the swfkrpano.js can be used for Flash,iPhone,iPad,
but the <object> / <embed> tags are Flashplayer Plugin only of course,

just see/read here:
http://krpano.com/docu/swfkrpanojs/

best regards,
Klaus

5

Monday, March 14th 2011, 4:22am

Hi Klaus,

Of course. I know the <object> / <embed> tags are Flashplayer Plugin only.

But I am so confuse why not work to change XML/pano on iphone by (embedpano({swf:"test2.swf", xml:"test2.xml", target:"pano"})

Link: (work at IE, but not work at iphone) *sad*
http://www.minkeystudio.com/test3/#




Could you give me simple example which can change XML/pano by javascript ,while it support both IE and iphone? Thanks you very much.

I found your example (http://krpano.com/examples/javascript1/) which is not support iphone/ipad.


Best Regards,
MInkey.

6

Monday, March 14th 2011, 10:18am

Hi,

you can change the xml by the loading a new xml with the loadpano() action,
're-embedding' the whole viewer itself doesn't work,

have a look at the included Javascript examples from the viewer download package,
they work also on iPhone/iPad,

best regards,
Klaus

7

Tuesday, March 15th 2011, 11:29am

Hi Klaus,

I am happy to get your reply *smile*

I try to use loadpano(). but not work both on Iphone/IE. *sad* *sad* *sad*

http://www.minkeystudio.com/test3/index2.html

I would like to clarify if loadpano() can only work inside XML? not work at javascipt function?



"re-embedding" Only work on IE/Safari/Firefox. not work on Iphone/Ipad. In fact, is it possible which can change XML/pano by javascript without refreshing the browser ,while it support both IE and iphone?


"have a look at the included Javascript examples from the viewer download package,
they work also on iPhone/iPad,"
<<<<< I dont' know why it is not work for me (I am using 3GS and ver3.1.2), Is my version too old?






Best Regards and Thanks,

Minkey

8

Wednesday, March 16th 2011, 8:18am

Thanks klaus, they are done well by javascript, and I see the javascript examples in the viewer download package, and make an other attempt. the script part is:

Source code

1
2
3
4
5
6
7
8
  <script type="text/javascript">
function krpano(){
return document.getElementById("krpanoSWFObject");}
function closespot(){
krpano.set("hotspot[hs1].visible","false");}
function openspot(){
krpano.set("hotspot[hs1].visible","true");}
</script>

the Html part is

Source code

1
2
3
4
5
6
7
8
9
10
11
<body>
<script src="1.js"></script>
<div id="pano" style="width:100%; height:70%;">
<noscript><table style="width:100%;height:100%;"><tr style="valign:middle;"><td><div style="text-align:center;">ERROR:<br/><br/>Javascript not activated<br/><br/></div></td></tr></table></noscript>
<script>
embedpano({swf:"1.swf", xml:"1.xml", target:"pano"});
</script>
</div><br>
<span id="close" onClick="closespot()">Close spot1</span>
<span id="open" onClick="openspot()"> Open spot1</span>
</body>


when I click on them ,they all dont work, what's wrong! Thanks!

9

Saturday, March 19th 2011, 11:53am

Hi,

I'm mean the examples in the viewer download package,
they work in Flash and iPhone/Pad

the online js examples from on docu page are not updated yet,

best regards,
Klaus