if ( SiSTeR == undefined ) { var SiSTeR = {}; } SiSTeR.getElementById = function (element) { var elements = new Array(); for (var i = 0; i < arguments.length; i++) { var element = arguments[i]; if (typeof element == 'string') element = document.getElementById(element); if (arguments.length == 1) return element; elements.push(element); } return elements; } SiSTeR.Event = { observers: false, _observeAndCache: function(element, name, observer, useCapture) { if (!this.observers) this.observers = []; if (element.addEventListener) { this.observers.push([element, name, observer, useCapture]); element.addEventListener(name, observer, useCapture); } else if (element.attachEvent) { this.observers.push([element, name, observer, useCapture]); element.attachEvent('on' + name, observer); } }, unloadCache: function() { if (!SiSTeR.Event.observers) return; for (var i = 0, length = Event.observers.length; i < length; i++) { SiSTeR.Event.stopObserving.apply(this, Event.observers[i]); SiSTeR.Event.observers[i][0] = null; } SiSTeR.Event.observers = false; }, observe: function(element, name, observer, useCapture) { element = SiSTeR.getElementById(element); useCapture = useCapture || false; if (name == 'keypress' && (navigator.appVersion.match(/Konqueror|Safari|KHTML/) || element.attachEvent)) name = 'keydown'; SiSTeR.Event._observeAndCache(element, name, observer, useCapture); }, stopObserving: function(element, name, observer, useCapture) { element = SiSTeR.getElementById(element); useCapture = useCapture || false; if (name == 'keypress' && (navigator.appVersion.match(/Konqueror|Safari|KHTML/) || element.detachEvent)) name = 'keydown'; if (element.removeEventListener) { element.removeEventListener(name, observer, useCapture); } else if (element.detachEvent) { try { element.detachEvent('on' + name, observer); } catch (e) {} } } } SiSTeR.Require = function(s) { document.write(''); } SiSTeR.Event.observe(window,"load",function() { var IE = /MSIE (\d+\.\d+);/.test(navigator.userAgent); var vincnt = SiSTeR.getElementById('VINCNT'); var VIN = ""; if (IE) { VIN = vincnt.childNodes[0].rows[0].cells[1].innerHTML; } else { VIN = vincnt.childNodes[1].rows[0].cells[1].innerHTML; } var mserver_path = "35007382172981:1659_042009"; var script = document.createElement("script"); script.setAttribute("type", "text/javascript"); script.setAttribute("src", "http://3df.pod0.sister.tv/3df/3df-dist-1.1-Reseller/cobalt/insert_cta.php" + "?mserver_path=" + mserver_path + "&VIN=" + VIN); document.getElementsByTagName("head").item(0).appendChild(script); }); function Draw3DFIcon() { if ( SiSTeR == undefined ) { var SiSTeR = {}; } var callsToAction = SiSTeR.getElementById('callsToAction'); var actionLink = document.createElement("div"); actionLink.setAttribute('class','actionLink'); actionLink.setAttribute('className','actionLink'); var a = document.createElement("a"); a.href="javascript:void(0)"; a.innerHTML = "Push Me"; actionLink.appendChild(a); callsToAction.appendChild(actionLink); SiSTeR.Event.observe(a,"click",openPopup); }