You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

1

Wednesday, September 28th 2011, 5:55pm

Dynamic Image Hotspots



Hello Fellow Krpano-ers!

First post, but long time reader. Thank you for such an awesome resource and Klaus thank you for such an awesome tool!

I am having difficulty incorporating OpenX within Krpano. I know I can create a div or iframe the tour, but for this particular project the best case would be from within.

HTML:

Source code

1
<script type='text/javascript' src='http://d1.openx.org/spcjs.php?id=52489&amp;target=_blank'></script>



XML:

Source code

1
url="http://d1.openx.org/avw.php?zoneid=227008&amp"onclick="openurl(http://d1.openx.org/ck.php?n=a3b9cd3d&amp)"




According to Klaus' documentation URL attribute the supported file types are: SWF, JPG, PNG, GIF.


When I insert the direct url the rest works, but this defeats the purpose of the ad server. I need to figure out a way for krpano to display the dynamic images from the ad server.


There are three invocation tag types offered by OpenX:


Javascript

Source code

1
2
<!--/* OpenX Javascript Tag v2.8.6-rc2 */-->
<script type='text/javascript'><!--//<![CDATA[   var m3_u = (location.protocol=='https:'?'https://d1.openx.org/ajs.php':'http://d1.openx.org/ajs.php');   var m3_r = Math.floor(Math.random()*99999999999);   if (!document.MAX_used) document.MAX_used = ',';   document.write ("<scr"+"ipt type='text/javascript' src='"+m3_u);   document.write ("?zoneid=227008&amp;target=_blank");   document.write ('&amp;cb=' + m3_r);   if (document.MAX_used != ',') document.write ("&amp;exclude=" + document.MAX_used);   document.write (document.charset ? '&amp;charset='+document.charset : (document.characterSet ? '&amp;charset='+document.characterSet : ''));   document.write ("&amp;loc=" + escape(window.location));   if (document.referrer) document.write ("&amp;referer=" + escape(document.referrer));   if (document.context) document.write ("&context=" + escape(document.context));   if (document.mmm_fo) document.write ("&amp;mmm_fo=1");   document.write ("'><\/scr"+"ipt>");//]]>--></script><noscript><a href='http://d1.openx.org/ck.php?n=aaa4dc28&amp;cb=INSERT_RANDOM_NUMBER_HERE' target='_blank'><img src='http://d1.openx.org/avw.php?zoneid=227008&amp;cb=INSERT_RANDOM_NUMBER_HERE&amp;n=aaa4dc28' border='0' alt='' /></a></noscript>




iframe

Source code

1
2
<!--/* OpenX Javascript Tag v2.8.6-rc2 */-->
<script type='text/javascript'><!--//<![CDATA[   var m3_u = (location.protocol=='https:'?'https://d1.openx.org/ajs.php':'http://d1.openx.org/ajs.php');   var m3_r = Math.floor(Math.random()*99999999999);   if (!document.MAX_used) document.MAX_used = ',';   document.write ("<scr"+"ipt type='text/javascript' src='"+m3_u);   document.write ("?zoneid=227008&amp;target=_blank");   document.write ('&amp;cb=' + m3_r);   if (document.MAX_used != ',') document.write ("&amp;exclude=" + document.MAX_used);   document.write (document.charset ? '&amp;charset='+document.charset : (document.characterSet ? '&amp;charset='+document.characterSet : ''));   document.write ("&amp;loc=" + escape(window.location));   if (document.referrer) document.write ("&amp;referer=" + escape(document.referrer));   if (document.context) document.write ("&context=" + escape(document.context));   if (document.mmm_fo) document.write ("&amp;mmm_fo=1");   document.write ("'><\/scr"+"ipt>");//]]>--></script><noscript><a href='http://d1.openx.org/ck.php?n=aaa4dc28&amp;cb=INSERT_RANDOM_NUMBER_HERE' target='_blank'><img src='http://d1.openx.org/avw.php?zoneid=227008&amp;cb=INSERT_RANDOM_NUMBER_HERE&amp;n=aaa4dc28' border='0' alt='' /></a></noscript>




imagetag


Source code

1
2
<!--/* OpenX Image Tag v2.8.6-rc2 */-->
<a href='http://d1.openx.org/ck.php?n=a3b9cd3d&amp;cb=INSERT_RANDOM_NUMBER_HERE' target='_blank'><img src='http://d1.openx.org/avw.php?zoneid=227008&amp;cb=INSERT_RANDOM_NUMBER_HERE&amp;n=a3b9cd3d' border='0' alt='' /></a>




What is the best way to go about doing this? I would appreciate any input. I am open to try anything.

Posts: 1,850

Occupation: Virtual Tours - Photography - Krpano developer

  • Send private message

2

Wednesday, September 28th 2011, 6:58pm

Use javascript to do whatever you have to do to get that URL and call your function within krpano.
KRPano Developer: Portfolio ::Gigapixel Tagging Solutions - Porfolio 2 :: Facebook :: Twitter :: reddit.com/r/VirtualTour

3

Wednesday, September 28th 2011, 7:29pm

Use javascript to do whatever you have to do to get t
Do you have an example of this in code I could check out somewhere else on the forum?

Similar threads