",""); e = e.replace("",""); document.getElementById("tcl-head").innerHTML =e; var hostHref = $($(".menu.fl").find('.mes')[0]).children('a').attr('href').match(/^https?:\/\/([a-z0-9_.:])+([\/p$])/g); var mes = $(".menu.fl").find('.mes') /*mes.each(function(index, value) { var eleMes = $(value) var eleHrefchannel = eleMes.children('a').attr('href').split('=')[1] if(index !== 0) { eleMes.children('a').attr('href', hostHref + eleHrefchannel) } })*/ self.runScripts(document.getElementById("tcl-head")); setTimeout(function(){ document.getElementById("tcl-head").style.display = "block"; },50) }, error:function(e){ console.log(e); } }); $.ajax({ url:'http://www.aeonhq.live/api/html/footer', type:"GET", contentType : 'application/json', data:"", success:function(e){ e = e.replace("",""); e = e.replace("",""); document.getElementById("tcl-foot").innerHTML =e; self.runScripts(document.getElementById("tcl-foot")); setTimeout(function(){ document.getElementById("tcl-foot").style.display = "block"; },50) }, error:function(e){ console.log(e); } }); }, seq:function(arr, callback, index) { var _self = this; if (typeof index === 'undefined') { index = 0 } arr[index](function () { index++ if (index === arr.length) { callback() } else { _self.seq(arr, callback, index) } }) }, scriptsDone:function() { var DOMContentLoadedEvent = document.createEvent('Event') DOMContentLoadedEvent.initEvent('DOMContentLoaded', true, true) document.dispatchEvent(DOMContentLoadedEvent) }, insertScript:function($script, callback) { var s = document.createElement('script') s.type = 'text/javascript' if ($script.src) { s.onload = callback s.onerror = callback s.src = $script.src } else { s.textContent = $script.innerText } document.head.appendChild(s) $script.parentNode.removeChild($script) if (!$script.src) { callback() } }, runScripts:function($container) { var _self = this; var $scripts = $container.querySelectorAll('script'); var runList = []; var typeAttr; [].forEach.call($scripts, function ($script,i) { typeAttr = $script.getAttribute('type') try { if (!typeAttr || _self.runScriptTypes.indexOf(typeAttr) !== -1) { runList.push(function (callback) { _self.insertScript($script, callback) }) } } catch (error) { console.log(error); } }) _self.seq(runList, _self.scriptsDone) } }; scriptRander.init(); function goAnchor(_index){ document.querySelector('#mapWrap'+_index).scrollIntoView(true); } //var pecent = current.innerrWidth/某個寬度; //area.coords * pecent; function fixSize(){ $('html').css('fontSize',(window.innerWidth/10)+'px'); $('area').each(function(index,ele){ var coords = ele.coords.split(','); var percnet = $(ele).parents('.Jwap').width()/750; for(var i=0;i