Plugin Directory

Changeset 649098


Ignore:
Timestamp:
01/07/2013 10:08:30 AM (13 years ago)
Author:
volcanodiscovery
Message:

Update

Location:
volcano-widget/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • volcano-widget/trunk/VolcanoWidget.php

    r639612 r649098  
    55Description: Interactive map of active volcanoes and current earthquakes world-wide
    66Author: Tom Pfeiffer
    7 Version: 1
     7Version: 1.1
    88Author URI: http://www.volcanodiscovery.com/
    99License: GPL2
     
    210210  var c=document.getElementById('VW_mCont');
    211211  var iFrame = document.getElementById('VW_iframe');
    212   //var VW_code = document.getElementById('VW_code');
    213   //var VW_code2 = document.getElementById('VW_code2');
    214212  var switchLink = document.getElementById('switchLink');
    215213  var VW_backDiv = document.getElementById('VW_backDiv');
     
    283281  document.getElementById('standAlone').href=widgetSrc1;
    284282  document.getElementById('standAlone').innerHTML=widgetSrc1;
    285   // workaround for IE...
    286   //VW_code.innerHTML = '<!-- begin VolcanoWidget -->\n'+iFrameCode+'\n<!-- end VolcanoWidget / http://www.volcano-news.com/active-volcanoes-map/get-widget.html -->\n\n';
    287283 
    288284  var enlarge = 'enlarge'; var small = 'small map';
     
    290286  if (lang==2) {enlarge = 'agrandir'; var small = 'petite carte';}
    291287  document.getElementById('VW_mSwitch').innerHTML = enlarge;
     288  // on preview
    292289  var onClick = "switchFrame('VW_smallMap','VW_bigMap','"+enlarge+"','"+small+"','"+width2+"','"+height+"px',"+lat+","+lon+");return false;"; 
    293290  switchLink.setAttribute('onClick',onClick);
    294291  VW_backDiv.setAttribute('onClick',onClick);
     292  // on live version
     293  var onClickCode = "switchFrame('VW_smallMap','VW_bigMap','"+enlarge+"','"+small+"','"+width+"','"+height+"px',"+lat+","+lon+");return false;"; 
    295294 
    296295  var finalCode = '<!-- begin VolcanoWidget -->\n<div id="VW_bigMap" style="display:none;position:fixed;top:0;left:0;width:100%;height:100%;z-index:999999;">\n<div id="VW_backDiv" style="background:#000;filter:alpha(opacity=80);opacity:.8;height:100%;width:100%;position:absolute;top:0px;left:0px;z-index:-1;" onclick="'+onClick+'"></div></div>';
    297296  finalCode += '\n<div id="VW_smallMap" style="clear:left"><div id="VW_mCont" style="width:'+width+';height:'+height+'px;position:relative;margin:0;background:#fff;"><a name="VW_mCont"></a>';
    298   finalCode += '<div style="position:absolute;top:8px;right:28px;height:15px;text-align:right;vertical-align:middle;font:12px Verdana,sans-serif;font-weight:bold">[<a href="#" style="color:#bb202a" onclick="'+onClick+'"><span id="VW_mSwitch">'+enlarge+'</span></a>]</div>';
     297  finalCode += '<div style="position:absolute;top:8px;right:28px;height:15px;text-align:right;vertical-align:middle;font:12px Verdana,sans-serif;font-weight:bold">[<a href="#" style="color:#bb202a" onclick="'+onClickCode+'"><span id="VW_mSwitch">'+enlarge+'</span></a>]</div>';
    299298  finalCode += iFrameCode2+'</div></div>\n';
    300299  finalCode += '<script type="text/javascript">'+'function switchFrame(a,b,c,d,e,f,g,h){var i=document.getElementById("VW_mCont");var j=document.getElementById("VW_mSwitch").firstChild;if(j.nodeValue==c){j.nodeValue=d}else{j.nodeValue=c}var k=i.parentNode.getAttribute("id");if(k==a){var l=b}else{var l=a}var m=i.parentNode;var n=document.getElementById(l);n.appendChild(i);m.style.display="none";n.style.display="";if(l==a){i.style.width=e;i.style.height=f;i.style.margin=0;i.style.top=""}else{i.style.width="80%";i.style.height="80%";i.style.margin="auto";i.style.top="20px"}window.location.hash="VW_mCont"}';
  • volcano-widget/trunk/readme.txt

    r639623 r649098  
    5252= 1.0 =
    5353* First release
     54= 1.1 =
     55Minor fix in javascript enlarge function: when returning to small map, the originally set width is restored
     56
    5457
    5558== Feature request ==
Note: See TracChangeset for help on using the changeset viewer.