You are not logged in.

> The forum rules have been updated. Please take a moment to read them.


#1 2013-02-05 12:10:12

frankvdh
Member
Registered: 2012-09-11
Posts: 32

open pano with html code

is there a way that besides the thumbnails within the pano i can call a pano with htmlcode like

<a href="" onclick="mainloadpano(virtualtour8.xml); return false;">Open thumbnail 8</a>

this would be a super cool function for me so any help would be much appreciated

Offline

 

#2 2013-02-05 12:53:03

mediavets
Moderator
From: Isleham, Cambridgeshire, UK.
Registered: 2007-11-14
Posts: 9728
Website

Re: open pano with html code

I'm not sure I understand - where would this code be placed? In your HTML page?

Perhaps this is what you seek?:

http://krpano.com/plugins/userplugins/swfaddress/#top

Or this?:

http://krpano.com/docu/js/#top

http://krpano.com/examples/10812/exampl … dpano.html

Last edited by mediavets (2013-02-05 13:00:26)


Andrew Stephens
Nikon D40, Nikkor 10.5mm fisheye, Sigma 8mm f3.5 fisheye, Nikkor 18-55/50/35mm lenses, Nodal Ninja 5 Lite, Nodal Ninja 4 with R-D16, Agno's MrotatorTCS short.
Nikon P5100, CP5000, CP995, FC-E8, WC-E63,WC-E68, TC-E2, Kaidan Kiwi 995, Bophoto pano bracket, Agno's MrotatorA.
Merlin/Orion robotic pano head + Papywizard on Nokia 770/N800/N810 and Windows 8/XP/2K.

Offline

 

#3 2013-02-05 13:40:07

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

yes
http://krpano.com/examples/10812/exampl … dpano.html

this is exactly what i mean, now i just have to take a look how i implement this

Offline

 

#4 2013-02-05 13:47:03

mediavets
Moderator
From: Isleham, Cambridgeshire, UK.
Registered: 2007-11-14
Posts: 9728
Website

Re: open pano with html code

frankvdh wrote:

yes
http://krpano.com/examples/10812/exampl … dpano.html

this is exactly what i mean, now i just have to take a look how i implement this

According to this doc page - see Examples section:

http://krpano.com/docu/js/#top

This is one of the examples included in the download package in the folder "examples/javascript-interface/".


Andrew Stephens
Nikon D40, Nikkor 10.5mm fisheye, Sigma 8mm f3.5 fisheye, Nikkor 18-55/50/35mm lenses, Nodal Ninja 5 Lite, Nodal Ninja 4 with R-D16, Agno's MrotatorTCS short.
Nikon P5100, CP5000, CP995, FC-E8, WC-E63,WC-E68, TC-E2, Kaidan Kiwi 995, Bophoto pano bracket, Agno's MrotatorA.
Merlin/Orion robotic pano head + Papywizard on Nokia 770/N800/N810 and Windows 8/XP/2K.

Offline

 

#5 2013-02-05 14:03:30

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

strange error, i even copied the complete html and every attached file of the demo  but for some reason i get the error

Object #<HTMLEmbedElement> has no method 'call'

anyone encountered that problem ?

the code is

Code:

<script>
// <![CDATA[

    embedpano({swf:"test/virtualtour.swf", id:"krpanoSWFObject", xml:"virtualtour1.xml", target:"krpanoDIV", width:"516", height:"300"});

    function krpano() 
    {
        return document.getElementById("krpanoSWFObject");
    }
    
    function loadpano(xmlname)
    {
        krpano().call("loadpano(" + xmlname + ", null, MERGE, BLEND(1));");
    }
    
// ]]>
</script>

see preview online http://server.active-vision.nl/test/testpanobuiten.html

Last edited by frankvdh (2013-02-05 14:13:30)

Offline

 

#6 2013-02-05 21:29:42

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

Strange you placed your swf into a test folder.... where as the xml data drivers are outside..

Try taking it out...

Destiny..


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#7 2013-02-05 21:40:40

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

well i first tryed it localhost, so thats the test folder and then i put it online so the code might be different then the link

de pano works, only the javascript loadpano doesnt because of the call functions

Offline

 

#8 2013-02-05 21:52:58

mediavets
Moderator
From: Isleham, Cambridgeshire, UK.
Registered: 2007-11-14
Posts: 9728
Website

Re: open pano with html code

frankvdh wrote:

well i first tryed it localhost, so thats the test folder and then i put it online so the code might be different then the link

de pano works, only the javascript loadpano doesnt because of the call functions

I don't know if this is relevant, but you must have an entry in the Restricted domains field in order for advanced javascript stuff to work:


Uploaded Images


Andrew Stephens
Nikon D40, Nikkor 10.5mm fisheye, Sigma 8mm f3.5 fisheye, Nikkor 18-55/50/35mm lenses, Nodal Ninja 5 Lite, Nodal Ninja 4 with R-D16, Agno's MrotatorTCS short.
Nikon P5100, CP5000, CP995, FC-E8, WC-E63,WC-E68, TC-E2, Kaidan Kiwi 995, Bophoto pano bracket, Agno's MrotatorA.
Merlin/Orion robotic pano head + Papywizard on Nokia 770/N800/N810 and Windows 8/XP/2K.

Offline

 

#9 2013-02-05 21:56:07

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

I guess I should have worked as you have it... Did you upload your swfkrpano.js file...

Destiny...

<script src="../../../swfkrpano.js"></script>

<script>
// <![CDATA[

    embedpano({swf:"../../../krpano.swf", id:"krpanoSWFObject", xml:"pano1.xml", target:"krpanoDIV", width:"516", height:"300"});

    function krpano()
    {
        return document.getElementById("krpanoSWFObject");
    }
   
    function loadpano(xmlname)
    {
        krpano().call("loadpano(" + xmlname + ", null, MERGE, BLEND(1));");
    }
   
// ]]>
</script>


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#10 2013-02-05 21:57:52

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

yes else the pano wouldnt show.. so everything works form the script, except the call function, so thats why i was so amazed

Offline

 

#11 2013-02-05 21:59:37

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

mediavets wrote:

frankvdh wrote:

well i first tryed it localhost, so thats the test folder and then i put it online so the code might be different then the link

de pano works, only the javascript loadpano doesnt because of the call functions

I don't know if this is relevant, but you must have an entry in the Restricted domains field in order for advanced javascript stuff to work:

so i need to select this to be able to use this function ?  of is it that i leave it blank all domains works for it ?

Offline

 

#12 2013-02-05 22:04:05

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

Did you provide the target to the "krpanoDIV".. in your html...

<div id="krpanoDIV" style="width:100%; height:100%;"><noscript><table width="100%" height="100%"><tr valign="middle"><td><center>ERROR:<br/><br/>Javascript not activated<br/><br/></center></td></tr></table></noscript></div>

Destiny..


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#13 2013-02-05 22:10:23

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

@destiny

yes, if it didnt then this


embedpano({swf:"../../../krpano.swf", id:"krpanoSWFObject", xml:"pano1.xml", target:"krpanoDIV", width:"516", height:"300"});


wouldnt show.. so that works

i really think its the call function, since chrome javascript console gives an error everytime that functions is called

Offline

 

#14 2013-02-05 22:14:02

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

Hi...  Did you add the onclick="loadpano('pano1.xml');

Destiny...


<body>

<center>   
    <br/>

    <table style="width:516px; height:auto; border:0;">
        <tr>
            <td colspan="2" style="height:100%">
                <div id="krpanoDIV" style="width:100%; height:100%;"><noscript><table width="100%" height="100%"><tr valign="middle"><td><center>ERROR:<br/><br/>Javascript not activated<br/><br/></center></td></tr></table></noscript></div>
            </td>
        </tr>
        <tr>
            <td>
                click the image to load the pano...<br/>
                <img src="thumb1.jpg" width="256" height="128" onclick="loadpano('pano1.xml');" />
            </td>
           
            <td>
                click the image to load the pano...<br/>
                <img src="thumb2.jpg" width="256" height="128" onclick="loadpano('pano2.xml');" />
            </td>
        </tr>
    </table>
   
</center>



<script src="../../../swfkrpano.js"></script>

<script>
// <![CDATA[

    embedpano({swf:"../../../krpano.swf", id:"krpanoSWFObject", xml:"pano1.xml", target:"krpanoDIV", width:"516", height:"300"});

    function krpano()
    {
        return document.getElementById("krpanoSWFObject");
    }
   
    function loadpano(xmlname)
    {
        krpano().call("loadpano(" + xmlname + ", null, MERGE, BLEND(1));");
    }
   
// ]]>
</script>


</body>
</html>


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#15 2013-02-05 22:18:39

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

@destiny yes

the onclick calls the loadpano function

and the loadpano function calls the call function..

so the bug is in the loadpano function

basicly it say that the callfunction doesnt exist and cant perform it

this
view-source:http://server.active-vision.nl/test/testpanobuiten.html

is an 100% copy of the example
http://krpano.com/examples/10812/exampl … dpano.html

EXCEPT... for the pano.. thats the only difference

Offline

 

#16 2013-02-05 22:19:54

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

The krpano demo works my end..... wink

Destiny..


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#17 2013-02-05 22:27:06

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

I am assuming you added this file.. swfkrpano.js
Also, it might be a case that it only works with he updated file...

Destiny..


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#18 2013-02-05 22:29:24

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

Hi.. you will find that yours doesn't work due to missing urls or missing files..

http://server.active-vision.nl/test/testpanobuiten.html

Destiny..


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#19 2013-02-05 22:47:10

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

@destiny

the only files that are missing are the 2 images, but that has no connection to the call function does it

and even when i fix that.. it doesnt help

so checkup

swfkrpano.js  100% copy of demo
html 100% copy of demo
images 100%copy of demo

pano not

so i think there is the problem not in the xml files

Offline

 

#20 2013-02-05 23:12:20

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

Perhaps change your JavaScript from loadpano to loadvirtualtour

You also need to add your thumb jpg files..

Destiny..


Uploaded Images


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#21 2013-02-05 23:29:22

mediavets
Moderator
From: Isleham, Cambridgeshire, UK.
Registered: 2007-11-14
Posts: 9728
Website

Re: open pano with html code

frankvdh wrote:

mediavets wrote:

I don't know if this is relevant, but you must have an entry in the Restricted domains field in order for advanced javascript stuff to work:

so i need to select this to be able to use this function ?

I believe so.


Andrew Stephens
Nikon D40, Nikkor 10.5mm fisheye, Sigma 8mm f3.5 fisheye, Nikkor 18-55/50/35mm lenses, Nodal Ninja 5 Lite, Nodal Ninja 4 with R-D16, Agno's MrotatorTCS short.
Nikon P5100, CP5000, CP995, FC-E8, WC-E63,WC-E68, TC-E2, Kaidan Kiwi 995, Bophoto pano bracket, Agno's MrotatorA.
Merlin/Orion robotic pano head + Papywizard on Nokia 770/N800/N810 and Windows 8/XP/2K.

Offline

 

#22 2013-02-06 00:27:34

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

I have tried to find reference to this in the advanced js but its not in the tour..

I have made a test too.. Same issue.. http://members.westnet.com.au/dps/advan … tiny2.html

It might be that fact that I created mine using ptp and which creates the xml code very differently..

Worth investigating more..

Destiny..


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#23 2013-02-06 09:12:15

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

well, yours gives me the same error

Offline

 

#24 2013-02-06 10:57:11

Destiny
Moderator
From: Australia
Registered: 2010-04-27
Posts: 2355
Website

Re: open pano with html code

Yes.. As you say, its not right yet.. Still working it out.. What seems to be simple isn't..
I think its the makeup of the xml and swf.. I will try to make a demo tour up again but use krpano.. There might be something written into the swf that makes it work since there are flash issues with it as it is when created using ptp.....

Destiny..


Virtual Tours and 3D/360 Object/Product Photographer - Our aim is to create a 3D/360 Virtual Tour Shop/Store with links to 3D/360 degree products. My gear, VR Drive II - D90 - Nikon 10.5 fisheye - Nikon D800 with Nikon-Nikkor 14-24 - NOVOFLEX Magic Balance - Acratech GP Ball-head - Nodal Ninja 4 + RD-16 Rotor - Manfrotto 190CXPRO4 Carbon Fiber Tripod smile smile

Offline

 

#25 2013-02-06 12:54:21

frankvdh
Member
Registered: 2012-09-11
Posts: 32

Re: open pano with html code

its a difficult problem and i agree with you thats it something between de xml and swf, i gonna try the restricted domains function maybe that wil help. if you find the problem let me know, but id like to thank you for your help and replies so far, much appreciated

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2005 Rickard Andersson