var wptheme_DebugUtils = { // summary: Collection of utilities for logging debug messages. enabled: false, log: function ( /*String*/className, /*String*/message ) { // summary: Logs a debugging message, if debugging is enabled. // className: the javascript class name or function name which is logging the message // message: the message to log if ( this.enabled ) { message = className + " ==> " + message; if ( typeof( console ) == "undefined" ) { console.debug( message ); } else { //better alternative for browsers that don't support console???? alert( message ); } } } } var wptheme_HTMLElementUtils = { // summary: Collection of utility functions useful for manipulating HTML elements in a cross-browser fashion. className: "wptheme_HTMLElementUtils", _debugUtils: wptheme_DebugUtils, _uniqueIdCounter: 0, getUniqueId: function () { // summary: Generates a unique identifier (to the current page) by appending a counter to a set prefix. // A page refresh resets the unique identifier counter. // returns: a unique identifier var retVal = "wptheme_unique_" + this._uniqueIdCounter; this._uniqueIdCounter++; return retVal; // String }, sizeToViewableArea: function ( /*HTMLElement*/element ) { // summary: Sizes the given element to the viewable area of the browser in a cross-browser fashion. // element: the html element to size var browserDimensions = new BrowserDimensions(); element.style.height = browserDimensions.getViewableAreaHeight() + "px"; element.style.width = browserDimensions.getViewableAreaWidth() + "px"; element.style.top = browserDimensions.getScrollFromTop() + "px"; element.style.left = browserDimensions.getScrollFromLeft() + "px"; }, sizeToEntireArea: function ( /*HTMLElement*/element ) { // summary: Sizes the given element to the viewable area plus the scroll area. // element: the html element to size var browserDimensions = new BrowserDimensions(); //The getHTMLElement*() functions return the exact size of the body element in IE even if the viewable area is //larger (i.e. no scroll bars). In Firefox, the dimensions of the viewable area plus the scrollable area is returned. //So in IE, we take the viewable area if that is larger and the HTMLElement* area if that is larger. element.style.height = Math.max( browserDimensions.getHTMLElementHeight(), browserDimensions.getViewableAreaHeight() ) + "px"; element.style.width = Math.max( browserDimensions.getHTMLElementWidth(), browserDimensions.getViewableAreaWidth() ) + "px"; }, sizeRelativeToViewableArea: function ( /*HTMLElement*/element, /*float*/heightFactor, /*float*/widthFactor ) { // summary: Sizes the given element to a certain multiple of the viewable area. For example, if heightFactor is 0.5, // the height of the given element will be set to half of the viewable area height. // element: the html element to size // heightFactor: the factor to multiply the viewable area height by // widthFactor: the factor to multiply the viewable area width by var browserDimensions = new BrowserDimensions(); element.style.height = ( browserDimensions.getViewableAreaHeight() * heightFactor ) + "px"; element.style.width = ( browserDimensions.getViewableAreaWidth() * widthFactor ) + "px"; }, positionRelativeToViewableArea: function ( /*HTMLElement*/element, /*float*/heightFactor, /*float*/widthFactor ) { // summary: Positions the given element relative to the viewable area. For example, if the heightFactor is 0.5, the // top of the element will be positioned (Y axis) halfway down the viewable area. Note that this means the element // will be ABSOLUTELY positioned. // element: the html element to position // heightFactor: the factor to multiply the viewable area height by // widthFactor: the factor to multiply the viewable area width by var browserDimensions = new BrowserDimensions(); element.style.position = "absolute"; if ( this._debugUtils.enabled ) { this._debugUtils.log( this.className, "Browser's viewable height: " + browserDimensions.getViewableAreaHeight() ); this._debugUtils.log( this.className, "Browser's viewable width: " + browserDimensions.getViewableAreaWidth() ); this._debugUtils.log( this.className, "Browser's scroll from top: " + browserDimensions.getScrollFromTop() ); this._debugUtils.log( this.className, "Browser's scroll from left: " + browserDimensions.getScrollFromLeft() ); } element.style.top = ( ( browserDimensions.getViewableAreaHeight() * heightFactor ) + browserDimensions.getScrollFromTop() ) + "px"; //Scroll left behaves differently in FF & IE in RTL languages. The "correct" behavior is up for debate. In FF, it will return the "correct" value //(scrollLeft switches when the page is rendered right-to-left). In IE, scroll left will basically return the scroll width for the body element. //There's no real "capability" to test for here so the window.attachEvent is a cheap trick to check for IE. //bidiSupport is defined in the theme. if ( bidiSupport.isRTL && window.attachEvent ) { if ( this._debugUtils.enabled ) { this._debugUtils.log( this.className, "scrollWidth = " + browserDimensions.getHTMLElementWidth() ); this._debugUtils.log( this.className, "clientWidth = " + browserDimensions.getViewableAreaWidth() ); this._debugUtils.log( this.className, "Scroll Offset should be: " + ( browserDimensions.getHTMLElementWidth() - browserDimensions.getViewableAreaWidth() - browserDimensions.getScrollFromLeft() ) ); } element.style.left = ( ( browserDimensions.getViewableAreaWidth() * widthFactor) + ( browserDimensions.getHTMLElementWidth() - browserDimensions.getViewableAreaWidth() - browserDimensions.getScrollFromLeft() ) ) + "px"; } else { element.style.left = ( ( browserDimensions.getViewableAreaWidth() * widthFactor ) + browserDimensions.getScrollFromLeft() ) + "px"; } }, positionOutsideElementTopRight: function ( /*HTMLElement*/elementToPosition, /*HTMLElement*/relativeElement ) { // summary: Positions the given element just outside (to the top and lining up with the right edge) of the // relative element. // description: Sets the top (Y-axis) position of the given element to the top of the relative element minus the // height of element being positioned. Sets the left (X-axis) position of the given element to the left position of // the relative element plus the width of the relative element (to get the right edge) minus the width of the element // being positioned (to line the end of the element being positioned up with the right edge of the relative element). elementToPosition.style.position = "absolute"; elementToPosition.style.top = ( this.stripUnits( relativeElement.style.top ) - elementToPosition.offsetHeight ) + "px"; if ( bidiSupport.isRTL ) { elementToPosition.style.left = ( this.stripUnits( relativeElement.style.left ) ) + "px"; } else { elementToPosition.style.left = ( this.stripUnits( relativeElement.style.left ) + relativeElement.offsetWidth - elementToPosition.offsetWidth) + "px"; } }, stripUnits: function ( /*String*/cssProp ) { // summary: Strips any units (i.e. "px") from a CSS style property. // returns: the number value minus any units return parseInt( cssProp.substring( 0, cssProp.length - 2 )); //integer }, addClassName: function ( /*HTMLElement*/element, /*String*/className ) { // summary: Adds the given className to the element's style definitions. // element: the HTMLElement to add the class name to // className: the className to add var clazz = element.className; if ( clazz.indexOf( className ) < 0 ) { element.className += (" " + className); } }, removeClassName: function ( /*HTMLElement*/element, /*String*/className ) { // summary: Removes the given className from the element's style definitions. // element: the HTMLElement to remove the class name from // className: the className to remove var clazz = element.className; var startIndex = clazz.indexOf( className ); if ( startIndex >= 0 ) { clazz = clazz.substring(0, startIndex) + clazz.substring( startIndex + className.length + 1 ); element.className = clazz; } }, hideElementsByTagName: function ( /*String 1...N*/) { // summary: Hides every element of a given tag name. Stores the old visibility style so it can be // restored by the showElementsByTagName function. for ( var i = 0; i < arguments.length; i++ ) { var elements = document.getElementsByTagName( arguments[i] ); for ( var j = 0; j < elements.length; j++ ) { if ( elements[j] && elements[j].style ) { elements[j]._oldVisibilityStyle = elements[j].style.visibility; elements[j].style.visibility = "hidden"; } } } }, showElementsByTagName: function ( /*String 1...N*/) { // summary: Shows every element of a given tag name. Uses the old visibility style so that elements hidden // by hideElementsByTagName are properly restored. for ( var i = 0; i < arguments.length; i++ ) { var elements = document.getElementsByTagName( arguments[i] ); for ( var j = 0; j < elements.length; j++ ) { if ( elements[j] && elements[j].style ) { if ( elements[j]._oldVisibility ) { elements[j].style.visibility = elements[j]._oldVisibility; elements[j]._oldVisibility = null; } else { elements[j].style.visibility = "visible"; } } } } }, addOnload: function ( /*Function*/func ) { // summary: Adds a function to be called on page load. // func: the function to call if ( window.addEventListener ) { window.addEventListener( "load", func, false ); } else if ( window.attachEvent ) { window.attachEvent( "onload", func ); } }, getEventObject: function ( /*Event?*/event ) { // summary: Cross-browser function to retrieve the event object. // event: In W3C-compliant browsers, this object will just simply be // returned // returns: the event object var result = event; if ( !event && window.event ) { result = window.event; } return result; // Event } } var wptheme_CookieUtils = { // summary: Various utility functions for dealing with cookies on the client. _deleteDate: new Date( "1/1/2003" ), _undefinedOrNull: function ( /*Object*/variable ) { // summary: Determines if a given variable is undefined or NULL. // returns: true if undefined OR NULL, false otherwise. return ( typeof ( variable ) == "undefined" || variable == null ); // boolean }, debug: wptheme_DebugUtils, className: "wptheme_CookieUtils", getCookie: function ( /*String*/cookieName ) { // summary: Gets the value for a given cookie name. If no value is found, returns NULL. if ( this.debug.enabled ) { this.debug.log( this.className, "getCookie( " + cookieName + " )" ); } cookieName = cookieName + "=" var retVal = null; if ( this.debug.enabled ) { this.debug.log( this.className, "document.cookie=" + document.cookie ); this.debug.log( this.className, "indexOf cookieName: " + document.cookie.indexOf( cookieName ) ); } if ( document.cookie.indexOf( cookieName ) >= 0 ) { var cookies = document.cookie.split(";"); var c = 0; if ( this.debug.enabled && cookies.length > 0 ) { this.debug.log( this.className, "cookies[0] = " + cookies[0] ); } while ( c < cookies.length && ( cookies[c].indexOf( cookieName ) == -1 ) ) { if ( this.debug.enabled ) { this.debug.log( this.className, "cookies[" + c + "] = " + cookies[0] ); } c=c+1; } //Make sure there's no leading or trailing spaces on our cookie name/value pair. var cookieNVP = cookies[c].replace( /^[ \s]+|[ \s]+$/, '' ); if ( this.debug.enabled ) { this.debug.log( this.className, "cookieName=\"" + cookieName + "\"." ); this.debug.log( this.className, "cookieName.length=\"" + cookieName.length + "\"." ); this.debug.log( this.className, "cookieNVP=\"" + cookieNVP + "\"." ); this.debug.log( this.className, "cookieNVP.length=\"" + cookieNVP.length + "\"." ); } var cookieValue = cookieNVP.substring( cookieName.length ); if ( this.debug.enabled ) { this.debug.log( this.className, "cookie value =\"" + cookieValue + "\"."); } if ( cookieValue != "null" ) { retVal = cookieValue; } } if ( this.debug.enabled ) { this.debug.log( this.className, "getCookie( " + cookieName + " ) return " + retVal ); } return retVal; // String }, setCookie: function ( /*String*/name, /*String*/value, /*Date?*/expiration, /*String?*/path ) { // summary: Creates the cookie based on the given information. // name: the name of the cookie // value: the value for the cookie // expiration: OPTIONAL -- when the cookie should expire // path: OPTIONAL -- the url path the cookie applies to if ( this.debug.enabled ) { this.debug.log( this.className, "set cookie (" + [ name, value, expiration, path ] + ")"); } if ( this._undefinedOrNull( name ) ) { throw Error( "Unable to set cookie! No name given!" ); } if ( this._undefinedOrNull( value ) ) { throw Error( "Unable to set cookie! No value given!" ); } if ( this._undefinedOrNull( expiration ) ) { expiration = ""; } else { expiration = "expiration=" + expiration.toUTCString() + ";"; } if ( this._undefinedOrNull( path ) ) { path = "path=/;"; } else { path = "path=" + path + ";"; } document.cookie=name + '=' + value + ';' + expiration + path; if ( this.debug.enabled ) { this.debug.log( this.className, "document.cookie after setting the cookie=" + document.cookie ); } }, deleteCookie: function ( /*String*/cookieName ) { // summary: Deletes a given cookie by setting the value to "null" and setting the expiration // value to expire completely. if ( this.debug.enabled ) { this.debug.log( this.className, "delete cookie (" + [ cookieName ] + ") "); } if(wpsFLY_isIE){ this.setCookie( cookieName, "null", this._deleteDate); }else{ this.setCookie( cookieName, ""); } } } function addLoadEvent(func) { var oldonload = window.onload; if (typeof window.onload != 'function') { window.onload = func; } else { window.onload = function() { if (oldonload) { oldonload(); } func(); } } } /************************************************************ * morning star tab page script */ function selectTab(wrapperName, tabName, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy) { var tabWrapperElem = document.getElementById("ms_li_wrapper_" + wrapperName); var tabCollection = getElementsByClass("ms_tab", tabWrapperElem, "li"); for (var i=0; i"; currentIframeDivWrapperElem.innerHTML = newIframeText; currentIframeDivWrapperElem.innerHTML = currentIframeDivWrapperElem.innerHTML; } /* DOM on IE has problem recognize object that closed without explicit close tag, i.e. problem on if (forceReload) { while (currentIframeDivWrapperElem.hasChildNodes()) { currentIframeDivWrapperElem.removeChild(currentIframeDivWrapperElem.lastChild); } } if (!currentIframeDivWrapperElem.hasChildNodes()) { var newIframeElem = document.createElement("iframe"); newIframeElem.id = "ms_iframe_" + tabName; newIframeElem.className = "ms_tab"; newIframeElem.width = iframeWidth; newIframeElem.height = iframeHeight; newIframeElem.frameBorder = 0; newIframeElem.scrolling = "no"; newIframeElem.name = iframeProxy + "ms_iframe_" + tabName; newIframeElem.src = iframeSrc; newIframeElem.setAttribute("allowtransparency", true); currentIframeDivWrapperElem.appendChild(newIframeElem); } */ } function registerTab(wrapperName, tabName, tabTitle, onload, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy) { var ua = navigator.userAgent.toLowerCase(); if (ua.indexOf( "firefox" ) != -1 || ua.indexOf( "mozilla" ) != -1) { dojo.addOnLoad(function () {registerTab2(wrapperName, tabName, tabTitle, onload, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy);}); } else { if (document.readyState=="complete") { registerTab2(wrapperName, tabName, tabTitle, onload, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy); } else { document.onreadystatechange = function () { if (document.readyState == "complete") { registerTab2(wrapperName, tabName, tabTitle, onload, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy); } } } } /* addLoadEvent(function() { registerTab2(wrapperName, tabName, tabTitle, onload, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy); } ) */ } function registerTab2(wrapperName, tabName, tabTitle, onload, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy) { var tabWrapperElem = document.getElementById("ms_li_wrapper_" + wrapperName); var newTabElem = document.createElement("li"); newTabElem.id = "ms_li_" + tabName; newTabElem.className = (onload) ? "ms_tab selected" : "ms_tab unselected"; var newAnchorElem = document.createElement("a"); newAnchorElem.href = "javascript:selectTab('" + wrapperName + "', '" + tabName + "', " + forceReload + ", " + iframeWidth + ", " + iframeHeight + ", '" + iframeSrc + "', '" + iframeProxy + "');"; var newTextElem = document.createTextNode(tabTitle); newAnchorElem.appendChild(newTextElem); newTabElem.appendChild(newAnchorElem); tabWrapperElem.appendChild(newTabElem); var iframeWrapperElem = document.getElementById("ms_iframe_wrapper_" + wrapperName); /* var innerHTMLText = iframeWrapperElem.innerHTML.toLowerCase(); if (innerHTMLText.indexOf("iframe") == -1) { var newIframeText = ""; newIframeText = newIframeText + ""; iframeWrapperElem.innerHTML = newIframeText; iframeWrapperElem.innerHTML = iframeWrapperElem.innerHTML; } */ var newIframeDivWrapperText = ""; newIframeDivWrapperText = newIframeDivWrapperText + "
"; iframeWrapperElem.innerHTML = iframeWrapperElem.innerHTML + newIframeDivWrapperText; iframeWrapperElem.innerHTML = iframeWrapperElem.innerHTML; /* DOM on IE has problem recognize object that closed without explicit close tag, i.e. problem on
, but no problem on
var newIframeDivWrapperElem = document.createElement("div"); newIframeDivWrapperElem.id = "ms_iframe_" + tabName + "_div_wrapper_" + wrapperName; newIframeDivWrapperElem.className = (onload) ? "ms_tab selected" : "ms_tab unselected"; iframeWrapperElem.appendChild(newIframeDivWrapperElem); */ if (onload) selectTab(wrapperName, tabName, forceReload, iframeWidth, iframeHeight, iframeSrc, iframeProxy); } /************************************************************ * morning star iframe script */ function getToken(searchString, startToken, endToken) { var startIndex = searchString.indexOf(startToken) + startToken.length; var endIndex = searchString.indexOf(endToken, startIndex); if (endIndex == -1) endIndex = searchString.length; return searchString.substring(startIndex, endIndex); } function setIframeHeight(iframeid, height) { try { var elem = document.getElementById(iframeid); if (elem != null) elem.height = height; } catch(err) { //Handle errors here } } var hash; function checkHash() { try { var data = location.hash ? location.hash.substring(1) : ''; if (hash != data ) { var iframeId = getToken(data, "iframeid=", "&"); var height = getToken(data, "height=", "&"); setIframeHeight(iframeId, height); fixFavicon(); } } catch(err) { //alert(err.message); }; } function fixFavicon() { try { var id = "favicon"; var oldLinkElem = document.getElementById(id); if (oldLinkElem != null) { var headElem = oldLinkElem.parentNode; var type = oldLinkElem.type; var rel = oldLinkElem.rel; var href = oldLinkElem.href; headElem.removeChild(oldLinkElem); var newLinkElem = document.createElement("link"); newLinkElem.id = id; newLinkElem.type = type; newLinkElem.rel = rel; newLinkElem.href = href; headElem.appendChild(newLinkElem); } } catch(err) { //Handle errors here } } setInterval(checkHash, 300); //detect whether hash is changed, if changed, later we can stop the interval. /************************************************************ * init logon menu box, show / hide menu * this is copied from www.aia.com.hk */ /* var adjustment = 234; var windowWidth = 667; var logonMenuID = document.getElementById('logonMenu'); var overLogonID = document.getElementById("Logon"); */ function initLogonMenu(){ var adjustment = 234; var windowWidth = 667; var logonMenuID = document.getElementById('logonMenu'); // logonLayerPostion = document.body.clientWidth / 2 + adjustment; // if(logonLayerPostion > windowWidth){ // logonMenuID.style.left = logonLayerPostion + 'px'; // }else{ // logonMenuID.style.left = windowWidth + 'px'; // } } function adjustPosition(){ var adjustment = 234; var windowWidth = 667; var logonMenuID = document.getElementById('logonMenu'); // logonLayerPostion = document.body.clientWidth / 2 + adjustment; // if(logonLayerPostion > windowWidth){ // logonMenuID.style.left = logonLayerPostion + 'px'; // } } function showMenu(imageSrc){ var overLogonID = document.getElementById("Login"); initLogonMenu(); document.getElementById('logonMenu').style.display = 'block'; if (imageSrc.length > 0) { overLogonID.setAttribute("src", imageSrc); } } function hideMenu(imageSrc){ var overLogonID = document.getElementById("Login"); initLogonMenu(); document.getElementById('logonMenu').style.display = 'none'; if (imageSrc.length > 0) { overLogonID.setAttribute("src", imageSrc); } } /************************************************************ * PNG Transparency Fix for IE 5.5 & 6 * this is copied from www.aia.com.au */ if (navigator.platform == "Win32" && navigator.appName == "Microsoft Internet Explorer" && window.attachEvent) { window.attachEvent("onload", enableAlphaImages); } function enableAlphaImages(){ var spacerPath = '../../images/common/spacer.gif'; var rslt = navigator.appVersion.match(/MSIE (\d+\.\d+)/, ''); var itsAllGood = (rslt != null && Number(rslt[1]) >= 5.5); if (itsAllGood) { for (var i=0; i= 5.5) && (document.body.filters)) { for(var i=0; i" img.outerHTML = strNewHTML i = i-1 } } } } function displayCustomerInfo() { var targetUrl = window.location.protocol + "//" + window.location.host + "/WMSSOAuth/SSOUserInfoJSON"; dojo.xhrGet({ url: targetUrl, load: function (response, ioArgs) { var userinfo = dojo.fromJson(response); var custinfo = dojo.byId("custinfo"); if ( custinfo != null ) custinfo.innerHTML = "Welcome " + userinfo.username + " email: "+userinfo.email + " 2FA at " + userinfo.mobile + ""; }, error: function (response, ioArgs) { }, sync: true, handleAs: 'text' }); } /*****Primary Navigation*******/ function showDiv(id){ try { var elem = document.getElementById(id); if (elem != null) elem.style.display = 'block'; } catch(err) { //Handle errors here } } function hideDiv(id){ try { var elem = document.getElementById(id); if (elem != null) elem.style.display = 'none'; } catch(err) { //Handle errors here } } function showPull(id) { try { var elem = document.getElementById(id); if (elem != null) { var anchors = elem.getElementsByTagName("a"); if (anchors.length > 0) showDiv(id); } } catch(err) { //Handle errors here } } function hidePull(id) { hideDiv(id); } /************Link*****************/ function generateNavigationPath(path, forceSecure, relativeToSite) { try { if (forceSecure == null) forceSecure = false; if (relativeToSite == null) relativeToSite = true; var newLocation = ((forceSecure) ? "https:" : window.location.protocol) + "//" + window.location.hostname; if (relativeToSite) { var arrPath = window.location.pathname.split("/"); newLocation += "/" + arrPath[1] + "/" + arrPath[2] + "/" + arrPath[3]; } newLocation += path; return newLocation; } catch(err) { //Handle errors here } } function navigateTo(path, forceSecure, relativeToSite) { try { var newLocation = generateNavigationPath(path, forceSecure, relativeToSite); window.location.assign(newLocation); } catch(err) { //Handle errors here } } function navigateNewWindow(path, forceSecure, relativeToSite) { try { var newLocation = generateNavigationPath(path, forceSecure, relativeToSite); window.open(newLocation, "_blank"); } catch(err) { //Handle errors here } } /************Get element by class*****************/ function getElementsByClass(className, node, tag) { var classElements = new Array(); if (node == null) node = document; if (tag == null) tag = '*'; var elemCollection = node.getElementsByTagName(tag); var length = elemCollection.length; var pattern = new RegExp("(^|\\s)" + className + "(\\s|$)"); for (var i = 0; i < length; i++) { if ( pattern.test(elemCollection[i].className) ) { classElements.push(elemCollection[i]); } } return classElements; } /* SWFObject v2.2 is released under the MIT License */ var swfobject=function(){var D="undefined",r="object",S="Shockwave Flash",W="ShockwaveFlash.ShockwaveFlash",q="application/x-shockwave-flash",R="SWFObjectExprInst",x="onreadystatechange",O=window,j=document,t=navigator,T=false,U=[h],o=[],N=[],I=[],l,Q,E,B,J=false,a=false,n,G,m=true,M=function(){var aa=typeof j.getElementById!=D&&typeof j.getElementsByTagName!=D&&typeof j.createElement!=D,ah=t.userAgent.toLowerCase(),Y=t.platform.toLowerCase(),ae=Y?/win/.test(Y):/win/.test(ah),ac=Y?/mac/.test(Y):/mac/.test(ah),af=/webkit/.test(ah)?parseFloat(ah.replace(/^.*webkit\/(\d+(\.\d+)?).*$/,"$1")):false,X=!+"\v1",ag=[0,0,0],ab=null;if(typeof t.plugins!=D&&typeof t.plugins[S]==r){ab=t.plugins[S].description;if(ab&&!(typeof t.mimeTypes!=D&&t.mimeTypes[q]&&!t.mimeTypes[q].enabledPlugin)){T=true;X=false;ab=ab.replace(/^.*\s+(\S+\s+\S+$)/,"$1");ag[0]=parseInt(ab.replace(/^(.*)\..*$/,"$1"),10);ag[1]=parseInt(ab.replace(/^.*\.(.*)\s.*$/,"$1"),10);ag[2]=/[a-zA-Z]/.test(ab)?parseInt(ab.replace(/^.*[a-zA-Z]+(.*)$/,"$1"),10):0}}else{if(typeof O.ActiveXObject!=D){try{var ad=new ActiveXObject(W);if(ad){ab=ad.GetVariable("$version");if(ab){X=true;ab=ab.split(" ")[1].split(",");ag=[parseInt(ab[0],10),parseInt(ab[1],10),parseInt(ab[2],10)]}}}catch(Z){}}}return{w3:aa,pv:ag,wk:af,ie:X,win:ae,mac:ac}}(),k=function(){if(!M.w3){return}if((typeof j.readyState!=D&&j.readyState=="complete")||(typeof j.readyState==D&&(j.getElementsByTagName("body")[0]||j.body))){f()}if(!J){if(typeof j.addEventListener!=D){j.addEventListener("DOMContentLoaded",f,false)}if(M.ie&&M.win){j.attachEvent(x,function(){if(j.readyState=="complete"){j.detachEvent(x,arguments.callee);f()}});if(O==top){(function(){if(J){return}try{j.documentElement.doScroll("left")}catch(X){setTimeout(arguments.callee,0);return}f()})()}}if(M.wk){(function(){if(J){return}if(!/loaded|complete/.test(j.readyState)){setTimeout(arguments.callee,0);return}f()})()}s(f)}}();function f(){if(J){return}try{var Z=j.getElementsByTagName("body")[0].appendChild(C("span"));Z.parentNode.removeChild(Z)}catch(aa){return}J=true;var X=U.length;for(var Y=0;Y0){for(var af=0;af0){var ae=c(Y);if(ae){if(F(o[af].swfVersion)&&!(M.wk&&M.wk<312)){w(Y,true);if(ab){aa.success=true;aa.ref=z(Y);ab(aa)}}else{if(o[af].expressInstall&&A()){var ai={};ai.data=o[af].expressInstall;ai.width=ae.getAttribute("width")||"0";ai.height=ae.getAttribute("height")||"0";if(ae.getAttribute("class")){ai.styleclass=ae.getAttribute("class")}if(ae.getAttribute("align")){ai.align=ae.getAttribute("align")}var ah={};var X=ae.getElementsByTagName("param");var ac=X.length;for(var ad=0;ad'}}aa.outerHTML='"+af+"";N[N.length]=ai.id;X=c(ai.id)}else{var Z=C(r);Z.setAttribute("type",q);for(var ac in ai){if(ai[ac]!=Object.prototype[ac]){if(ac.toLowerCase()=="styleclass"){Z.setAttribute("class",ai[ac])}else{if(ac.toLowerCase()!="classid"){Z.setAttribute(ac,ai[ac])}}}}for(var ab in ag){if(ag[ab]!=Object.prototype[ab]&&ab.toLowerCase()!="movie"){e(Z,ab,ag[ab])}}aa.parentNode.replaceChild(Z,aa);X=Z}}return X}function e(Z,X,Y){var aa=C("param");aa.setAttribute("name",X);aa.setAttribute("value",Y);Z.appendChild(aa)}function y(Y){var X=c(Y);if(X&&X.nodeName=="OBJECT"){if(M.ie&&M.win){X.style.display="none";(function(){if(X.readyState==4){b(Y)}else{setTimeout(arguments.callee,10)}})()}else{X.parentNode.removeChild(X)}}}function b(Z){var Y=c(Z);if(Y){for(var X in Y){if(typeof Y[X]=="function"){Y[X]=null}}Y.parentNode.removeChild(Y)}}function c(Z){var X=null;try{X=j.getElementById(Z)}catch(Y){}return X}function C(X){return j.createElement(X)}function i(Z,X,Y){Z.attachEvent(X,Y);I[I.length]=[Z,X,Y]}function F(Z){var Y=M.pv,X=Z.split(".");X[0]=parseInt(X[0],10);X[1]=parseInt(X[1],10)||0;X[2]=parseInt(X[2],10)||0;return(Y[0]>X[0]||(Y[0]==X[0]&&Y[1]>X[1])||(Y[0]==X[0]&&Y[1]==X[1]&&Y[2]>=X[2]))?true:false}function v(ac,Y,ad,ab){if(M.ie&&M.mac){return}var aa=j.getElementsByTagName("head")[0];if(!aa){return}var X=(ad&&typeof ad=="string")?ad:"screen";if(ab){n=null;G=null}if(!n||G!=X){var Z=C("style");Z.setAttribute("type","text/css");Z.setAttribute("media",X);n=aa.appendChild(Z);if(M.ie&&M.win&&typeof j.styleSheets!=D&&j.styleSheets.length>0){n=j.styleSheets[j.styleSheets.length-1]}G=X}if(M.ie&&M.win){if(n&&typeof n.addRule==r){n.addRule(ac,Y)}}else{if(n&&typeof j.createTextNode!=D){n.appendChild(j.createTextNode(ac+" {"+Y+"}"))}}}function w(Z,X){if(!m){return}var Y=X?"visible":"hidden";if(J&&c(Z)){c(Z).style.visibility=Y}else{v("#"+Z,"visibility:"+Y)}}function L(Y){var Z=/[\\\"<>\.;]/;var X=Z.exec(Y)!=null;return X&&typeof encodeURIComponent!=D?encodeURIComponent(Y):Y}var d=function(){if(M.ie&&M.win){window.attachEvent("onunload",function(){var ac=I.length;for(var ab=0;ab