
window.QZONE=window.QZONE||{};QZONE.FrontPage=QZONE.FrontPage||{};var getCookie=QZONE.cookie.get,setCookie=QZONE.cookie.set,deleteCookie=QZONE.cookie.del,imgcacheDomain="imgcache.qq.com",g_iLoginUin=checkLogin();;function checkLogin(){if(g_iLoginUin>10000){return g_iLoginUin;}else if(QZONE.cookie.get("skey")){var t=parseInt(getCookie("uin").replace(/[^\d]/g,""),10);if(!isNaN(t)&&(t>10000))
return t;else
return 0;}else{return 0;}};QZONE.FrontPage.appendPopupFn=function(fn){if(typeof(fn)=='function'){var _self=QZONE.FrontPage.popupDialog;if(!(_self._fnl instanceof Array)){_self._fnl=[];}
_self._fnl.push(fn);}};QZONE.FrontPage.showLoginBox=function(key,callbackFn,exappid,pOpt,sOpt){sOpt=sOpt||{};pOpt=pOpt||{};exappid-=0;var _self=QZONE.FrontPage.showLoginBox,url,path='http%3A%2F%2F'+imgcacheDomain+'%2Fqzone%2Fv5%2Flogin',ePath=path+'err.html',sPath=path+'succ.html',ps=genHttpParamString(sOpt),para=ps&&encodeURIComponent('&'+ps)||'',urlPara=key&&('%3fpara%3d'+encodeURIComponent(key)+para)||"";url=['http://ui.ptlogin2.qq.com/cgi-bin/login?hide_title_bar=1&link_target=blank&appid='+(exappid||15004501),'target='+(pOpt.target||"self"),'f_url='+(encodeURIComponent(pOpt.fu||'')||ePath),'s_url='+(encodeURIComponent(pOpt.su||QZONE.FrontPage.showLoginBox.href||'')||(sPath+urlPara))];if(!pOpt.mode){url.push('qlogin_jumpname=jump&qlogin_param=u1%3Dhttp%3A//qzone.qq.com/new.html'+urlPara);}
url=url.join("&");QZONE.FrontPage._specialPopup(_self,escHTML(pOpt.title||'')||"登录Qzone",url,378,280);typeof(QZONE.toolbar.refresh)=='function'&&QZONE.toolbar.refresh();_self._dialog.onUnload=function(){typeof(callbackFn)=='function'&&callbackFn()}};QZONE.FrontPage._specialPopup=function(_self,title,src,width,height){var content='<iframe width="'+(width-2)+'" height="'+height+'" frameborder="0" allowtransparency="yes" src="'+src+'"/>';if(!_self._dialog){_self._dialog=QZFL.dialog.create(title,content,width,height,false);}
if(!_self._ppml){var _z=_self._dialog.getZIndex();_self._ppml=QZONE.maskLayout.create(_z-1);}
_self._dialog.onBeforeUnload=function(){QZONE.maskLayout.remove(_self._ppml);_self._ppml=null;_self._dialog=null;return true;}}
QZONE.FrontPage.addFriend=QZONE.FrontPage.addFriend||function(uin,sid,care){if(checkLogin()<10001){QZONE.FrontPage.showLoginBox("fav");return;}
if(!uin){uin=g_iUin;}
sid=sid||0;care=care||false;var TFRIEND_USER_AUTHENTICATE="http://base.qzone.qq.com/cgi-bin/tfriend/friend_authfriend.cgi";var data={"uin":checkLogin(),"ouin":uin,"rd":Math.random()};var t=new QZONE.FormSender(TFRIEND_USER_AUTHENTICATE,"post",data,"utf-8");t.onSuccess=function(re){if(re&&re.ret=="succ"){if(!care){QZONE.FrontPage.popupDialog("添加好友",{"src":("/qzone/newfriend/newfriend_add.html?ouin="+uin+"&sid="+sid+"&state="+re.state+(re.state==3?("&q="+encodeURIComponent(re.question)):""))},428,260);}else{QZONE.FrontPage.popupDialog("添加关注",{"src":("/qzone/newfriend/newfriend_add.html?ouin="+uin+"&sid="+sid+"&state="+4)},428,260);}}else{QZONE.FrontPage.showMsgbox(re.msg,1,3000);if(re.type=='login'){QZONE.FrontPage.showLoginBox("mall");}}};t.onError=function(){QZONE.FrontPage.showMsgbox("由于网络或服务器问题，操作失败，请稍后再试。",1,3000);};t.send();};QZONE.FrontPage.showMsgbox=QZONE.widget.msgbox.show;QZONE.FrontPage.popupDialog=QZONE.FrontPage.popupDialog||function(title,html,width,height){var _self=QZONE.FrontPage.popupDialog;if(typeof(width)=='undefined'){width=430;}
if(typeof(height)=='undefined'){height=300;}
if(typeof(html)=='object'){html=_self._ifrmTmp.replace(/__p__/g,' src="'+html.src+'" height="'+(height)+'" width="'+(width-2)+'"');}else{html=html+"";}
var _dh,b;if(!_self._cpp){_dh=_self._cpp=QZONE.dialog.create(title+"",html,width,height);b=$("dialog_button_"+_dh._id);b.onclick=QZONE.FrontPage.closePopup;if(!_self._ppml){_self._ppml=QZONE.maskLayout.create();}}
_self._fnl=null;_self._fnl=[];};QZONE.FrontPage.popupDialog._ifrmTmp=QZONE.FrontPage.popupDialog._ifrmTmp||'<iframe frameborder="no" allowtransparency="yes"__p__></iframe>';QZONE.FrontPage.closePopup=QZONE.FrontPage.closePopup||function(){var _self=QZONE.FrontPage.popupDialog;var tmp,tf;if(typeof(window.popupCallback)=='function'){QZONE.FrontPage.appendPopupFn(window.popupCallback);}
tmp=_self._fnl;if(tmp&&tmp.length>0){_self._cpp.onUnload=function(){for(;tmp.length>0;){tf=tmp.pop();if(typeof(tf)=='function'){tf();}}
window.popupCallback=null;}}
if(_self._cpp){_self._cpp.unload();_self._cpp=null;}
if(_self._ppml){QZONE.maskLayout.remove(_self._ppml);_self._ppml=null;}};QZONE.FrontPage.loadToolbar=function(){QZONE.css.insertCSSLink("/qzonestyle/global/css/qzfl.css");QZONE.shareObject.create("/qzone/dataset/getset.swf");var flag=ENV.get("toolbarLoaded");if(!flag){QZONE.toolbar={};var t=new QZONE.jsLoader();t.onload=function(){ENV.set("toolbarLoaded",true);QZONE.toolbar.bootstrap();};t.load("/qzone/v5/toolbar.js",null,"utf-8");}else{if(QZONE.toolbar){QZONE.toolbar.refresh();}}}
var showLoginBox=QZONE.FrontPage.showLoginBox,_tgvshowLoginBox=showLoginBox,popupDialog=QZONE.FrontPage.popupDialog,closePopup=QZONE.FrontPage.closePopup,loadToolbar=QZONE.FrontPage.loadToolbar;/*  |xGv00|dd07ca249ea8cb7574e70bec287352b3 */