if(function(){if(typeof slogin=="object")for(method in slogin)if(method=="slogin"&&slogin.method)return!1;return!0}){Array.indexOf||(Array.prototype.indexOf=function(a){for(var b=0;b0){var b,c;for(c in a)if(c in a&&a[c].src&&0time-1e3)return!1;slogin.lastClickTime=time;var providerName=el.getAttribute("x-login-button"),href=slogin.protocol+"://"+slogin.sloginHost+"/"+providerName+"?host="+"&redirect_uri="+slogin.linkParams.redirect_uri;typeof slogin.linkParams["receiver"]!="undefined"&&(href+="&receiver="+slogin.linkParams.receiver),typeof slogin.linkParams["required"]!="undefined"&&(href+="&required="+slogin.linkParams.required),typeof slogin.linkParams["optional"]!="undefined"&&(href+="&optional="+slogin.linkParams.optional),typeof slogin.linkParams["nocache"]!="undefined"&&(href+="&nocache="+slogin.linkParams.nocache);var url=slogin.protocol+"://"+slogin.sloginHost+"/"+providerName+"?token";if(slogin.openWindow){var m=window.open(href,"slogin","scrollbars=1,width=800,height=600,left="+(screen.width-800)/2+",top="+(screen.height-600)/2);slogin.nWay==1&&(n=window.setInterval(function(){if(m&&m.closed){socket=slogin.initSocket(url);try{socket.postMessage("ready"),window.clearInterval(n)}catch(e){window.setTimeout(function(){socket.postMessage("ready"),window.clearInterval(n)},200)}}},100))}else location.href=href}))},easyXDMadd:function(url){if(!slogin.easyxdmDone){var a=document.createElement("script");a.src=slogin.protocol+"://"+slogin.sloginHost+"/js/easyXDM.min.js",document.body.appendChild(a),slogin.easyxdmDone=!0}},initSocket:function(url){var socket=new easyXDM.Socket({remote:url,swf:slogin.isIE()?slogin.protocol+"://"+slogin.sloginHost+"/js/easyxdm.swf":"",onMessage:function(message,origin){-1