/**
 * Cookie plugin
 *
 * Copyright (c) 2006 Klaus Hartl (stilbuero.de)
 * Dual licensed under the MIT and GPL licenses:
 * http://www.opensource.org/licenses/mit-license.php
 * http://www.gnu.org/licenses/gpl.html
 *
 */

jQuery.cookie=function(a,b,c){if(typeof b!='undefined'){c=c||{};if(b===null){b='';c.expires=-1}var d='';if(c.expires&&(typeof c.expires=='number'||c.expires.toUTCString)){var e;if(typeof c.expires=='number'){e=new Date();e.setTime(e.getTime()+(c.expires*24*60*60*1000))}else{e=c.expires}d='; expires='+e.toUTCString()}var f=c.path?'; path='+(c.path):'';var g=c.domain?'; domain='+(c.domain):'';var h=c.secure?'; secure':'';document.cookie=[a,'=',encodeURIComponent(b),d,f,g,h].join('')}else{var j=null;if(document.cookie&&document.cookie!=''){var k=document.cookie.split(';');for(var i=0;i<k.length;i++){var l=jQuery.trim(k[i]);if(l.substring(0,a.length+1)==(a+'=')){j=decodeURIComponent(l.substring(a.length+1));break}}}return j}};


/**
 * SWFObject v1.5: Flash Player detection and embed - http://blog.deconcept.com/swfobject/
 *
 * SWFObject is (c) 2007 Geoff Stearns and is released under the MIT License:
 * http://www.opensource.org/licenses/mit-license.php
 *
 */
if(typeof deconcept=="undefined"){var deconcept=new Object();}if(typeof deconcept.util=="undefined"){deconcept.util=new Object();}if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object();}deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a){if(!document.getElementById){return;}this.DETECT_KEY=_a?_a:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params=new Object();this.variables=new Object();this.attributes=new Array();if(_1){this.setAttribute("swf",_1);}if(id){this.setAttribute("id",id);}if(w){this.setAttribute("width",w);}if(h){this.setAttribute("height",h);}if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")));}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){deconcept.SWFObject.doPrepUnload=true;}if(c){this.addParam("bgcolor",c);}var q=_7?_7:"high";this.addParam("quality",q);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var _c=(_8)?_8:window.location;this.setAttribute("xiRedirectUrl",_c);this.setAttribute("redirectUrl","");if(_9){this.setAttribute("redirectUrl",_9);}};deconcept.SWFObject.prototype={useExpressInstall:function(_d){this.xiSWFPath=!_d?"expressinstall.swf":_d;this.setAttribute("useExpressInstall",true);},setAttribute:function(_e,_f){this.attributes[_e]=_f;},getAttribute:function(_10){return this.attributes[_10];},addParam:function(_11,_12){this.params[_11]=_12;},getParams:function(){return this.params;},addVariable:function(_13,_14){this.variables[_13]=_14;},getVariable:function(_15){return this.variables[_15];},getVariables:function(){return this.variables;},getVariablePairs:function(){var _16=new Array();var key;var _18=this.getVariables();for(key in _18){_16[_16.length]=key+"="+_18[key];}return _16;},getSWFHTML:function(){var _19="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath);}_19="<embed type=\"application/x-shockwave-flash\" src=\""+this.getAttribute("swf")+"\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\"";_19+=" id=\""+this.getAttribute("id")+"\" name=\""+this.getAttribute("id")+"\" ";var _1a=this.getParams();for(var key in _1a){_19+=[key]+"=\""+_1a[key]+"\" ";}var _1c=this.getVariablePairs().join("&");if(_1c.length>0){_19+="flashvars=\""+_1c+"\"";}_19+="/>";}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath);}_19="<object id=\""+this.getAttribute("id")+"\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\" style=\""+this.getAttribute("style")+"\">";_19+="<param name=\"movie\" value=\""+this.getAttribute("swf")+"\" />";var _1d=this.getParams();for(var key in _1d){_19+="<param name=\""+key+"\" value=\""+_1d[key]+"\" />";}var _1f=this.getVariablePairs().join("&");if(_1f.length>0){_19+="<param name=\"flashvars\" value=\""+_1f+"\" />";}_19+="</object>";}return _19;},write:function(_20){if(this.getAttribute("useExpressInstall")){var _21=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title);}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var n=(typeof _20=="string")?document.getElementById(_20):_20;n.innerHTML=this.getSWFHTML();return true;}else{if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"));}}return false;}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var _23=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var x=navigator.plugins["Shockwave Flash"];if(x&&x.description){_23=new deconcept.PlayerVersion(x.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var axo=1;var _26=3;while(axo){try{_26++;axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+_26);_23=new deconcept.PlayerVersion([_26,0,0]);}catch(e){axo=null;}}}else{try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");}catch(e){try{var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");_23=new deconcept.PlayerVersion([6,0,21]);axo.AllowScriptAccess="always";}catch(e){if(_23.major==6){return _23;}}try{axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}catch(e){}}if(axo!=null){_23=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));}}}return _23;};deconcept.PlayerVersion=function(_29){this.major=_29[0]!=null?parseInt(_29[0]):0;this.minor=_29[1]!=null?parseInt(_29[1]):0;this.rev=_29[2]!=null?parseInt(_29[2]):0;};deconcept.PlayerVersion.prototype.versionIsValid=function(fv){if(this.major<fv.major){return false;}if(this.major>fv.major){return true;}if(this.minor<fv.minor){return false;}if(this.minor>fv.minor){return true;}if(this.rev<fv.rev){return false;}return true;};deconcept.util={getRequestParameter:function(_2b){var q=document.location.search||document.location.hash;if(_2b==null){return q;}if(q){var _2d=q.substring(1).split("&");for(var i=0;i<_2d.length;i++){if(_2d[i].substring(0,_2d[i].indexOf("="))==_2b){return _2d[i].substring((_2d[i].indexOf("=")+1));}}}return "";}};deconcept.SWFObjectUtil.cleanupSWFs=function(){var _2f=document.getElementsByTagName("OBJECT");for(var i=_2f.length-1;i>=0;i--){_2f[i].style.display="none";for(var x in _2f[i]){if(typeof _2f[i][x]=="function"){_2f[i][x]=function(){};}}}};if(deconcept.SWFObject.doPrepUnload){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs);};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true;}}if(!document.getElementById&&document.all){document.getElementById=function(id){return document.all[id];};}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject;


/**
 * jQuery.ScrollTo
 * Copyright (c) 2007-2009 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com
 * Dual licensed under MIT and GPL.
 * Date: 5/25/2009
 *
 * @projectDescription Easy element scrolling using jQuery.
 * http://flesler.blogspot.com/2007/10/jqueryscrollto.html
 *
 * @author Ariel Flesler
 * @version 1.4.2
 *
 */

(function($){var h=$.scrollTo=function(a,b,c){$(window).scrollTo(a,b,c)};h.defaults={axis:'xy',duration:parseFloat($.fn.jquery)>=1.3?0:1};h.window=function(a){return $(window)._scrollable()};$.fn._scrollable=function(){return this.map(function(){var a=this,isWin=!a.nodeName||$.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!isWin)return a;var b=(a.contentWindow||a).document||a.ownerDocument||a;return $.browser.safari||b.compatMode=='BackCompat'?b.body:b.documentElement})};$.fn.scrollTo=function(e,f,g){if(typeof f=='object'){g=f;f=0}if(typeof g=='function')g={onAfter:g};if(e=='max')e=9e9;g=$.extend({},h.defaults,g);f=f||g.speed||g.duration;g.queue=g.queue&&g.axis.length>1;if(g.queue)f/=2;g.offset=both(g.offset);g.over=both(g.over);return this._scrollable().each(function(){var d=this,$elem=$(d),targ=e,toff,attr={},win=$elem.is('html,body');switch(typeof targ){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(targ)){targ=both(targ);break}targ=$(targ,this);case'object':if(targ.is||targ.style)toff=(targ=$(targ)).offset()}$.each(g.axis.split(''),function(i,a){var b=a=='x'?'Left':'Top',pos=b.toLowerCase(),key='scroll'+b,old=d[key],max=h.max(d,a);if(toff){attr[key]=toff[pos]+(win?0:old-$elem.offset()[pos]);if(g.margin){attr[key]-=parseInt(targ.css('margin'+b))||0;attr[key]-=parseInt(targ.css('border'+b+'Width'))||0}attr[key]+=g.offset[pos]||0;if(g.over[pos])attr[key]+=targ[a=='x'?'width':'height']()*g.over[pos]}else{var c=targ[pos];attr[key]=c.slice&&c.slice(-1)=='%'?parseFloat(c)/100*max:c}if(/^\d+$/.test(attr[key]))attr[key]=attr[key]<=0?0:Math.min(attr[key],max);if(!i&&g.queue){if(old!=attr[key])animate(g.onAfterFirst);delete attr[key]}});animate(g.onAfter);function animate(a){$elem.animate(attr,f,g.easing,a&&function(){a.call(this,e,g)})}}).end()};h.max=function(a,b){var c=b=='x'?'Width':'Height',scroll='scroll'+c;if(!$(a).is('html,body'))return a[scroll]-$(a)[c.toLowerCase()]();var d='client'+c,html=a.ownerDocument.documentElement,body=a.ownerDocument.body;return Math.max(html[scroll],body[scroll])-Math.min(html[d],body[d])};function both(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery);if(typeof(jqcc)==="undefined"){jqcc=jQuery}(function($){$.cometchat=function(){var _1="http://www.dfwhauntedhouses.com/forums/cometchat/";var _2=new Array();var _3=[];_2[0] = 'Chat Options';
_2[1] = 'Type your message and hit the enter key!';
_2[2] = 'My Status';
_2[3] = 'Available';
_2[4] = 'Busy';
_2[5] = 'Invisible';
_2[6] = 'Add Friend';
_2[7] = '<a href="faq.php?faq=vb3_user_profile#faq_vb3_friends_contacts">Learn how to add friends</a>';
_2[8] = 'Please login to use chat';
_2[9] = 'Who\'s Online';
_2[10] = 'Me';
_2[11] = 'Go Offline';
_2[12] = 'Who\'s Online';
_2[13] = 'Disable sound notifications';
_2[14] = 'You have no friends in your friend list, please add a few friends to use chat';
_2[15] = 'New Messages...';
_2[16] = '';
_3[0] = ['home.png','Home','/'];
_3[1] = ['chatrooms.png','Chatrooms','http://www.dfwhauntedhouses.com/forums/cometchat/modules/chatrooms/index.php','_popup','500','300'];
var _4 = ['filetransfer','divider','clearconversation','chattime'];
var _5 = 1;var _6 = 1;var _7 = 'dark';var _8 = 3000;var _9 = 12000;var _a=new Array();var _b=new Array();var _c={};var _d={};var _e={};var _f="";var _10=0;var _11=0;var _12=true;var _13=0;var ie6=false;var _14;var _15;var _16=_8;var _17=1;var _18=0;var _19=0;var _1a=0;var _1b="";var _1c=document.title;var _1d=0;var _1e={};var _1f={};var _20={};var _21={};var _22={};var _23={};var _24={};var _25={};var _26={};var _27=new Date();var _28=_27.getDate();var _29=Math.floor(_27.getTime()/1000);$.ajaxSetup({scriptCharset:"utf-8"});if(_6==1){$("<div id=\"cometchatflashcontent\"></div>").appendTo($("body"));var _2a={};var _2b={};var _2c={id:"cometchatbeep",name:"cometchatbeep"};var so;so=new SWFObject(_1+"swf/sound.swf","cometchatbeep","1","1","8","#ffffff");so.write("cometchatflashcontent")}function _2d(_2e){var _2f=navigator.appName.indexOf("Microsoft")!=-1;return(_2f)?window[_2e]:document[_2e]};function _30(){try{_2d("cometchatbeep").cometchatbeep()}catch(error){_6=0}};function _31(id,_32,_33){if($("#cometchat_tooltip").length>0){$("#cometchat_tooltip .cometchat_tooltip_content").html(_32)}else{$("body").append("<div id=\"cometchat_tooltip\"><div class=\"cometchat_tooltip_content\">"+_32+"</div></div>")}var pos=$("#"+id).offset();var _34=$("#"+id).width();var _35=$("#cometchat_tooltip").width();if(_33==1){$("#cometchat_tooltip").css("bottom",29).css("left",(pos.left+_34)-16).css("display","block").addClass("cometchat_tooltip_left")}else{$("#cometchat_tooltip").css("bottom",29).css("left",(pos.left+_34)-_35+12).css("display","block").removeClass("cometchat_tooltip_left")}if(ie6){$("#cometchat_tooltip").css("position","absolute");$("#cometchat_tooltip").css("top",parseInt($(window).height())-parseInt($("#cometchat_tooltip").css("bottom"))-parseInt($("#cometchat_tooltip").height())+$(window).scrollTop()+"px")}};function _36(_37,_38,id){if(_37.keyCode==13&&_37.shiftKey==0){var _39=$(_38).val();_39=_39.replace(/^\s+|\s+$/g,"");$(_38).val("");$(_38).css("height","18px");$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").css("height","200px");$(_38).css("overflow-y","hidden");$(_38).focus();if(_39!=""){$.post(_1+"cometchat_send.php",{to:id,message:_39},function(_3a){if(_3a){_ab(id,_39,"1","1",_3a,1,Math.floor(new Date().getTime()/1000));$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").scrollTop($("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext")[0].scrollHeight)}_17=1;if(_16>_8){_16=_8;clearTimeout(_14);_14=setTimeout(function(){_3b()},_8)}})}return false}};function _3c(_3d,_3e){if(_3d.keyCode==13&&_3d.shiftKey==0){var _3f=$(_3e).val();if(_3f!=""){$.post(_1+"cometchat_send.php",{statusmessage:_3f},function(_40){$(_3e).blur()})}return false}};function _41(_42,_43,id){var _44=_43.clientHeight;var _45=94;if(_45>_44){_44=Math.max(_43.scrollHeight,_44);if(_45){_44=Math.min(_45,_44)}if(_44>_43.clientHeight){$(_43).css("height",_44+4+"px");$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").css("height",218-(_44+4)+"px")}}else{$(_43).css("overflow-y","auto")}$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").scrollTop($("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext")[0].scrollHeight)};function _46(){$("#cometchat_optionsbutton_popup .busy").css("text-decoration","none");$("#cometchat_optionsbutton_popup .invisible").css("text-decoration","none");$("#cometchat_optionsbutton_popup .available").css("text-decoration","none");$("#cometchat_userstab_icon").removeClass("cometchat_user_available2");$("#cometchat_userstab_icon").removeClass("cometchat_user_busy2");$("#cometchat_userstab_icon").removeClass("cometchat_user_invisible2")};function _47(_48){$.post(_1+"cometchat_send.php",{status:_48},function(_49){})};function _4a(_4b){_11=1;_46();$("#cometchat_userstab_icon").addClass("cometchat_user_invisible2");if(_4b!=1){_47("offline")}$("#cometchat_userstab_popup").removeClass("cometchat_tabopen");$("#cometchat_userstab").removeClass("cometchat_userstabclick").removeClass("cometchat_tabclick");$("#cometchat_optionsbutton_popup").removeClass("cometchat_tabopen");$("#cometchat_optionsbutton").removeClass("cometchat_tabclick");_4c("buddylist","0");$("#cometchat_userstab_text").html("Offline")};function _4d(){$("<span/>").attr("id","cometchat_optionsbutton").addClass("cometchat_tab").addClass("cometchat_optionsimages").appendTo($("#cometchat_base"));$("<div/>").attr("id","cometchat_optionsbutton_popup").addClass("cometchat_tabpopup").css("display","none").html("<div class=\"cometchat_userstabtitle\">"+_2[0]+"</div><div class=\"cometchat_tabsubtitle\">"+_2[1]+"</div><div class=\"cometchat_tabcontent cometchat_optionstyle\"><strong>"+_2[2]+"</strong><br/><textarea class=\"cometchat_statustextarea\"></textarea><span style=\"float:left\" class=\"cometchat_user_available\"></span><span class=\"cometchat_optionsstatus available\">"+_2[3]+"</span><span class=\"cometchat_optionsstatus2 cometchat_user_busy\"></span><span class=\"cometchat_optionsstatus busy\">"+_2[4]+"</span><span class=\"cometchat_optionsstatus2 cometchat_user_invisible\"></span><span class=\"cometchat_optionsstatus invisible\">"+_2[5]+"</span><br clear=\"all\"/><div style=\"border-top:1px solid #eeeeee;margin-top:10px;padding-top:4px;\"><span><input type=\"checkbox\" id=\"cometchat_soundnotifications\" style=\"vertical-align: -2px;\">"+_2[13]+"</span></div><div style=\"border-top:1px solid #eeeeee;padding-top:10px;margin-top:4px;\"><span><strong>"+_2[6]+"</strong><br/><br/>"+_2[7]+"</span></div>").appendTo($("body"));$("#cometchat_soundnotifications").click(function(_4e){$.cookie("cometchat_sound",$("#cometchat_soundnotifications").attr("checked"),{path:"/",expires:365})});$("#cometchat_optionsbutton_popup .available").click(function(_4f){_46();$("#cometchat_userstab_icon").addClass("cometchat_user_available2");$(this).css("text-decoration","underline");_47("available")});$("#cometchat_optionsbutton_popup .busy").click(function(_50){_46();$("#cometchat_userstab_icon").addClass("cometchat_user_busy2");$(this).css("text-decoration","underline");_47("busy")});$("#cometchat_optionsbutton_popup .invisible").click(function(_51){_46();$("#cometchat_userstab_icon").addClass("cometchat_user_invisible2");$(this).css("text-decoration","underline");_47("invisible")});$("#cometchat_optionsbutton_popup .cometchat_statustextarea").keydown(function(_52){return _3c(_52,this)});$("#cometchat_optionsbutton").mouseover(function(){if(!$("#cometchat_optionsbutton_popup").hasClass("cometchat_tabopen")){if(_10==0){_31("cometchat_optionsbutton",_2[0])}else{_31("cometchat_optionsbutton",_2[8])}}$(this).addClass("cometchat_tabmouseover")});$("#cometchat_optionsbutton").mouseout(function(){$(this).removeClass("cometchat_tabmouseover");$("#cometchat_tooltip").css("display","none")});$("#cometchat_optionsbutton").click(function(){if(_1b!=""){$("#cometchat_trayicon_"+_1b+"_popup").removeClass("cometchat_tabopen");$("#cometchat_trayicon_"+_1b).removeClass("cometchat_trayclick");_1b=""}if(_10==0){if(_11==1){_11=0;$("#cometchat_userstab_text").html(_2[9]+" ("+_1a+")");_3b();$("#cometchat_optionsbutton_popup .available").click()}$("#cometchat_tooltip").css("display","none");$("#cometchat_optionsbutton_popup").css("left",$("#cometchat_optionsbutton").position().left-171).css("bottom","24px");$(this).toggleClass("cometchat_tabclick");$("#cometchat_optionsbutton_popup").toggleClass("cometchat_tabopen");$("#cometchat_optionsbutton").toggleClass("cometchat_optionsimages_click");$("#cometchat_userstab_popup").removeClass("cometchat_tabopen");$("#cometchat_userstab").removeClass("cometchat_userstabclick").removeClass("cometchat_tabclick");_4c("buddylist","0");if($.cookie("cometchat_sound")){if($.cookie("cometchat_sound")=="true"){$("#cometchat_soundnotifications").attr("checked",true)}else{$("#cometchat_soundnotifications").attr("checked",false)}}}else{if(_2[16]!=""){location.href=_2[16]}}});$("#cometchat_optionsbutton_popup .cometchat_userstabtitle").click(function(){$("#cometchat_optionsbutton").click()});$("#cometchat_optionsbutton_popup .cometchat_userstabtitle").mouseenter(function(){$(this).addClass("cometchat_chatboxtabtitlemouseover2")});$("#cometchat_optionsbutton_popup .cometchat_userstabtitle").mouseleave(function(){$(this).removeClass("cometchat_chatboxtabtitlemouseover2")})};function _53(){var _54="";var _55=0;for(chatbox in _23){if(_23[chatbox]!=null){_54+=chatbox+"|"+_23[chatbox]+",";if(_23[chatbox]>0){_55=1}}}_1d=_55;_54=_54.slice(0,-1);_4c("activeChatboxes",_54)};function _56(id,_57,_58,_59,_5a,_5b,_5c,_5d){if(id==null||id==""){return}if(_1e[id]==null||_1e[id]==""){if(_25[id]!=1){_25[id]=1;$.ajax({url:_1+"cometchat_getid.php",data:{userid:id},type:"post",cache:false,dataFilter:function(_5e){if(typeof(JSON)!=="undefined"&&typeof(JSON.parse)==="function"){return JSON.parse(_5e)}else{return eval("("+_5e+")")}},success:function(_5f){if(_5f){_57=_1e[id]=_5f.n;_58=_20[id]=_5f.s;_59=_1f[id]=_5f.m;_5a=_21[id]=_5f.a;_5b=_22[id]=_5f.l;if(_24[id]!=null){$("#cometchat_user_"+id+" .cometchat_closebox_bottom_status").removeClass("cometchat_available").removeClass("cometchat_busy").removeClass("cometchat_offline").addClass("cometchat_"+_58);if($("#cometchat_user_"+id+"_popup").length>0){$("#cometchat_user_"+id+"_popup .cometchat_tabsubtitle .cometchat_message").html(_59)}}_25[id]=0;_60(id,_57,_58,_59,_5a,_5b,_5c,_5d)}}})}else{setTimeout(function(){_56(id,_1e[id],_20[id],_1f[id],_21[id],_22[id],_5c,_5d)},500)}}else{_60(id,_1e[id],_20[id],_1f[id],_21[id],_22[id],_5c,_5d)}};function _60(id,_61,_62,_63,_64,_65,_66,_67){if(_24[id]!=null){if(!$("#cometchat_user_"+id).hasClass("cometchat_tabclick")&&_66!=1){if(_f!=""){$("#cometchat_user_"+_f+"_popup").removeClass("cometchat_tabopen");$("#cometchat_user_"+_f).removeClass("cometchat_tabclick").removeClass("cometchat_usertabclick");_f="";_4c("openChatboxId",_f)}if(($("#cometchat_user_"+id).offset().left<($("#cometchat_chatboxes").offset().left+$("#cometchat_chatboxes").width()))&&($("#cometchat_user_"+id).offset().left-$("#cometchat_chatboxes").offset().left)>=0){$("#cometchat_user_"+id).click()}else{$(".cometchat_tabalert").css("display","none");var ms=800;if(_68("initialize")==1){ms=0}$("#cometchat_chatboxes").scrollTo("#cometchat_user_"+id,ms,function(){$("#cometchat_user_"+id).click();_6f();_84()})}}_6f();return}$("#cometchat_chatboxes_wide").width($("#cometchat_chatboxes_wide").width()+152);_89();if(_61.length>12){shortname=_61.substr(0,12)+"..."}else{shortname=_61}if(_61.length>24){longname=_61.substr(0,24)+"..."}else{longname=_61}$("<span/>").attr("id","cometchat_user_"+id).addClass("cometchat_tab").html("<div style=\"float:left\">"+shortname+"</div>").appendTo($("#cometchat_chatboxes_wide"));$("#cometchat_user_"+id).append("<div class=\"cometchat_closebox_bottom_status cometchat_"+_62+"\"></div>");$("#cometchat_user_"+id).append("<div class=\"cometchat_closebox_bottom\"></div>");$("#cometchat_user_"+id+" .cometchat_closebox_bottom").mouseenter(function(){$(this).addClass("cometchat_closebox_bottomhover")});$("#cometchat_user_"+id+" .cometchat_closebox_bottom").mouseleave(function(){$(this).removeClass("cometchat_closebox_bottomhover")});$("#cometchat_user_"+id+" .cometchat_closebox_bottom").click(function(){$("#cometchat_user_"+id+"_popup").remove();$("#cometchat_user_"+id).remove();if(_f==id){_f="";_4c("openChatboxId",_f)}$("#cometchat_chatboxes_wide").width($("#cometchat_chatboxes_wide").width()-152);$("#cometchat_chatboxes").scrollTo("-=152px");_89();_23[id]=null;_24[id]=null;_26[id]=0;_53()});var _69="";if(_4.length>0){_69+="<div class=\"cometchat_plugins\">";for(var i=0;i<_4.length;i++){if(_4[i]=="divider"){_69+="<img src=\""+_1+"themes/"+_7+"/images/divider.png\" class=\"cometchat_pluginsicon_divider\">"}else{var _61="cc"+_4[i];_69+="<img src=\""+_1+"plugins/"+_4[i]+"/icon.png\" class=\"cometchat_pluginsicon\" title=\""+$[_61].getTitle()+"\" onclick=\"javascript:jqcc."+_61+".init("+id+");\">"}}_69+="</div>"}var _6a="";var _6b="";if(_65!=""){_6a="<a href=\""+_65+"\">";_6b="</a>"}var _6c="";if(_64!=""){_6c="<div class=\"cometchat_avatarbox\">"+_6a+"<img src=\""+_64+"\" class=\"cometchat_avatar\" />"+_6b+"</div>"}$("<div/>").attr("id","cometchat_user_"+id+"_popup").addClass("cometchat_tabpopup").css("display","none").html("<div class=\"cometchat_tabtitle\"><div class=\"cometchat_name\">"+_6a+longname+_6b+"</div></div><div class=\"cometchat_tabsubtitle\">"+_6c+"<div class=\"cometchat_message\">"+_63+"</div>"+_69+"<div style=\"clear:both\"></div>"+"</div><div class=\"cometchat_tabcontent\"><div class=\"cometchat_tabcontenttext\" id=\"cometchat_tabcontenttext_"+id+"\"></div><div class=\"cometchat_tabcontentinput\"><textarea class=\"cometchat_textarea\" ></textarea></div></div>").appendTo($("body"));$("#cometchat_user_"+id+"_popup .cometchat_textarea").keydown(function(_6d){return _36(_6d,this,id)});$("#cometchat_user_"+id+"_popup .cometchat_textarea").keyup(function(_6e){return _41(_6e,this,id)});$("#cometchat_user_"+id+"_popup .cometchat_tabtitle").append("<div class=\"cometchat_closebox\"></div><br clear=\"all\"/>");$("#cometchat_user_"+id+"_popup .cometchat_tabtitle .cometchat_closebox").mouseenter(function(){$(this).addClass("cometchat_chatboxmouseoverclose");$("#cometchat_user_"+id+"_popup .cometchat_tabtitle").removeClass("cometchat_chatboxtabtitlemouseover")});$("#cometchat_user_"+id+"_popup .cometchat_tabtitle .cometchat_closebox").mouseleave(function(){$(this).removeClass("cometchat_chatboxmouseoverclose");$("#cometchat_user_"+id+"_popup .cometchat_tabtitle").addClass("cometchat_chatboxtabtitlemouseover")});$("#cometchat_user_"+id+"_popup .cometchat_tabtitle .cometchat_closebox").click(function(){$("#cometchat_user_"+id+"_popup").remove();$("#cometchat_user_"+id).remove();if(_f==id){_f="";_4c("openChatboxId",_f)}$("#cometchat_chatboxes_wide").width($("#cometchat_chatboxes_wide").width()-152);$("#cometchat_chatboxes").scrollTo("-=152px");_89();_24[id]=null;_23[id]=null;_26[id]=0;_53()});$("#cometchat_user_"+id+"_popup .cometchat_tabtitle").click(function(){$("#cometchat_user_"+id).click()});$("#cometchat_user_"+id+"_popup .cometchat_tabtitle").mouseenter(function(){$(this).addClass("cometchat_chatboxtabtitlemouseover")});$("#cometchat_user_"+id+"_popup .cometchat_tabtitle").mouseleave(function(){$(this).removeClass("cometchat_chatboxtabtitlemouseover")});$("#cometchat_user_"+id).mouseenter(function(){$(this).addClass("cometchat_tabmouseover");$("#cometchat_user_"+id+" div").addClass("cometchat_tabmouseovertext")});$("#cometchat_user_"+id).mouseleave(function(){$(this).removeClass("cometchat_tabmouseover");$("#cometchat_user_"+id+" div").removeClass("cometchat_tabmouseovertext")});$("#cometchat_user_"+id).click(function(){if(_1b!=""){$("#cometchat_trayicon_"+_1b+"_popup").removeClass("cometchat_tabopen");$("#cometchat_trayicon_"+_1b).removeClass("cometchat_trayclick");_1b=""}if($("#cometchat_user_"+id+" .cometchat_tabalert").length>0){$("#cometchat_user_"+id+" .cometchat_tabalert").remove();_24[id]=0;_23[id]=0;_53()}if($(this).hasClass("cometchat_tabclick")){$(this).removeClass("cometchat_tabclick").removeClass("cometchat_usertabclick");$("#cometchat_user_"+id+"_popup").removeClass("cometchat_tabopen");$("#cometchat_user_"+id+" .cometchat_closebox_bottom").removeClass("cometchat_closebox_bottom_click");_f="";_4c("openChatboxId",_f)}else{if(_f!=""){$("#cometchat_user_"+_f+"_popup").removeClass("cometchat_tabopen");$("#cometchat_user_"+_f).removeClass("cometchat_tabclick").removeClass("cometchat_usertabclick");$("#cometchat_user_"+_f+" .cometchat_closebox_bottom").removeClass("cometchat_closebox_bottom_click");_f="";_4c("openChatboxId",_f)}if(!(($("#cometchat_user_"+id).offset().left<($("#cometchat_chatboxes").offset().left+$("#cometchat_chatboxes").width()))&&($("#cometchat_user_"+id).offset().left-$("#cometchat_chatboxes").offset().left)>=0)){$("#cometchat_chatboxes").scrollTo("#cometchat_user_"+id);_6f()}$("#cometchat_user_"+id+"_popup").css("left",$("#cometchat_user_"+id).position().left-62).css("bottom","24px");$(this).addClass("cometchat_tabclick").addClass("cometchat_usertabclick");$("#cometchat_user_"+id+"_popup").addClass("cometchat_tabopen");$("#cometchat_user_"+id+" .cometchat_closebox_bottom").addClass("cometchat_closebox_bottom_click");_f=id;_4c("openChatboxId",_f);if(_26[id]!=1&&_68("initialize")!=1){_70(id);_26[id]=1}if(ie6){$("#cometchat_user_"+_f+"_popup").css("position","absolute");$("#cometchat_user_"+_f+"_popup").css("top",parseInt($(window).height())-parseInt($("#cometchat_user_"+_f+"_popup").css("bottom"))-parseInt($("#cometchat_user_"+_f+"_popup").height())+$(window).scrollTop()+"px")}}$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").scrollTop($("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext")[0].scrollHeight);if(_71("updatingsession")!=1){$("#cometchat_user_"+id+"_popup .cometchat_textarea").focus()}});if(_66!=1){$("#cometchat_user_"+id).click()}_23[id]=0;_24[id]=0;_53()};function _72(ts){var ap="am";var _73=ts.getHours();var _74=ts.getMinutes();var _75=ts.getDate();var _76=ts.getMonth();if(_73>11){ap="pm"}if(_73>12){_73=_73-12}if(_73==0){_73=12}if(_73<10){_73=_73}if(_74<10){_74="0"+_74}var _77=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Nov","Dec"];var _78="th";if(_75==1||_75==21||_75==31){_78="st"}else{if(_75==2||_75==22){_78="nd"}else{if(_75==3||_75==23){_78="rd"}}}if(_75!=_28){return"<span class=\"cometchat_ts\">("+_73+":"+_74+ap+" "+_75+_78+" "+_77[_76]+")</span>"}else{return"<span class=\"cometchat_ts\">("+_73+":"+_74+ap+")</span>"}};function _70(id){$.ajax({url:_1+"cometchat_receive.php",data:{chatbox:id},type:"post",cache:false,dataFilter:function(_79){if(typeof(JSON)!=="undefined"&&typeof(JSON.parse)==="function"){return JSON.parse(_79)}else{return eval("("+_79+")")}},success:function(_7a){if(_7a){$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").html("");var _7b="";var _7c=_1e[id];$.each(_7a,function(_7d,_7e){if(_7d=="messages"){$.each(_7e,function(i,_7f){var _80="";if(_7f.self==1){fromname=_2[10];_80=" cometchat_self"}else{fromname=_7c}var ts=new Date(_7f.sent*1000);if(fromname.indexOf(" ")!=-1){fromname=fromname.slice(0,fromname.indexOf(" "))}_7b+=("<div class=\"cometchat_chatboxmessage\" id=\"cometchat_message_"+_7f.id+"\"><span class=\"cometchat_chatboxmessagefrom"+_80+"\"><strong>"+fromname+"</strong>:&nbsp;&nbsp;</span><span class=\"cometchat_chatboxmessagecontent"+_80+"\">"+_7f.message+"</span>"+_72(ts)+"</div>")})}});_d4("cometchat_tabcontenttext_"+id,"<div>"+_7b+"</div>"+document.getElementById("cometchat_tabcontenttext_"+id).innerHTML);$("#cometchat_tabcontenttext_"+id).scrollTop(50000);setTimeout("$(\"#cometchat_tabcontenttext_"+id+"\").scrollTop(50000)",100)}}})};function _81(id,_82,add){if(_1e[id]==null||_1e[id]==""){setTimeout(function(){_81(id,_82,add)},500)}else{_83(id);if(add==1){if($("#cometchat_user_"+id+" .cometchat_tabalert").length>0){_82=parseInt($("#cometchat_user_"+id+" .cometchat_tabalert").html())+parseInt(_82)}}if(_82==0){$("#cometchat_user_"+id+" .cometchat_tabalert").remove()}else{if($("#cometchat_user_"+id+" .cometchat_tabalert").length>0){$("#cometchat_user_"+id+" .cometchat_tabalert").html(_82)}else{$("<div/>").css("top","-5px").addClass("cometchat_tabalert").html(_82).appendTo($("#cometchat_user_"+id))}}_23[id]=_82;_53();_84()}};function _85(){var _86=$.cookie("cc_state");var _87=0;if(_86!=null){var _88=_86.split(/:/);_87=_88[3]}$("<span/>").attr("id","cometchat_userstab").addClass("cometchat_tab").html("<span id=\"cometchat_userstab_icon\"></span><span id=\"cometchat_userstab_text\" style=\"float:left\">"+_2[9]+" ("+_87+")</span>").appendTo($("#cometchat_base"));$("<div/>").attr("id","cometchat_userstab_popup").addClass("cometchat_tabpopup").css("display","none").html("<div class=\"cometchat_userstabtitle\">"+_2[9]+"</div><div class=\"cometchat_tabsubtitle\"><a class=\"cometchat_gooffline\">"+_2[11]+"</a></div><div class=\"cometchat_tabcontent cometchat_tabstyle\"><div id=\"cometchat_userscontent\"><div id=\"cometchat_userslist_available\"></div><div id=\"cometchat_userslist_busy\"></div><div id=\"cometchat_userslist_away\"></div><div id=\"cometchat_userslist_offline\"></div></div>").appendTo($("body"));$("#cometchat_userstab_popup .cometchat_gooffline").click(function(){_4a()});$("#cometchat_userstab_popup .cometchat_userstabtitle").click(function(){$("#cometchat_userstab").click()});$("#cometchat_userstab_popup .cometchat_userstabtitle").mouseenter(function(){$(this).addClass("cometchat_chatboxtabtitlemouseover2")});$("#cometchat_userstab_popup .cometchat_userstabtitle").mouseleave(function(){$(this).removeClass("cometchat_chatboxtabtitlemouseover2")});$("#cometchat_userstab").mouseover(function(){$(this).addClass("cometchat_tabmouseover")});$("#cometchat_userstab").mouseout(function(){$(this).removeClass("cometchat_tabmouseover")});$("#cometchat_userstab").click(function(){if(_1b!=""){$("#cometchat_trayicon_"+_1b+"_popup").removeClass("cometchat_tabopen");$("#cometchat_trayicon_"+_1b).removeClass("cometchat_trayclick");_1b=""}if(_11==1){_11=0;$("#cometchat_userstab_text").html(_2[9]+" ("+_1a+")");_3b();$("#cometchat_optionsbutton_popup .available").click()}$("#cometchat_optionsbutton_popup").removeClass("cometchat_tabopen");$("#cometchat_optionsbutton").removeClass("cometchat_tabclick");if($(this).hasClass("cometchat_tabclick")){_4c("buddylist","0")}else{_4c("buddylist","1")}$("#cometchat_userstab_popup").css("left",$("#cometchat_userstab").position().left+16).css("bottom","24px");$(this).toggleClass("cometchat_tabclick").toggleClass("cometchat_userstabclick");$("#cometchat_userstab_popup").toggleClass("cometchat_tabopen")})};function _89(){var _8a=$(window).width();var _8b=0;if(!$("#cometchat_chatbox_right").hasClass("cometchat_chatbox_lr")){_8b=19}if(_3.length>0){_8b+=(_3.length-1)*30}if(_8a<520+_8b){_8a=520+_8b}$("#cometchat_base").css("width",_8a-31);if($("#cometchat_chatboxes_wide").width()<=($("#cometchat_base").width()-226-_8b-75)){$("#cometchat_chatboxes").css("width",$("#cometchat_chatboxes_wide").width());$("#cometchat_chatboxes").scrollTo("0px",0)}else{var _8c=$("#cometchat_chatboxes").width();$("#cometchat_chatboxes").css("width",Math.floor(($("#cometchat_base").width()-226-_8b-75)/152)*152);var _8d=$("#cometchat_chatboxes").width();if(_8c!=_8d){$("#cometchat_chatboxes").scrollTo("-=152px",0)}}$("#cometchat_optionsbutton_popup").css("left",$("#cometchat_optionsbutton").position().left-171).css("bottom","24px");$("#cometchat_userstab_popup").css("left",$("#cometchat_userstab").position().left+16).css("bottom","24px");if(_f!=""){if(($("#cometchat_user_"+_f).offset().left<($("#cometchat_chatboxes").offset().left+$("#cometchat_chatboxes").width()))&&($("#cometchat_user_"+_f).offset().left-$("#cometchat_chatboxes").offset().left)>=0){$("#cometchat_user_"+_f+"_popup").css("left",$("#cometchat_user_"+_f).position().left-62).css("bottom","24px")}else{$("#cometchat_user_"+_f+"_popup").removeClass("cometchat_tabopen");$("#cometchat_user_"+_f).removeClass("cometchat_tabclick").removeClass("cometchat_usertabclick");var _8e=(($("#cometchat_user_"+_f).offset().left-$("#cometchat_chatboxes_wide").offset().left))-((Math.floor(($("#cometchat_chatboxes").width()/152))-1)*152);$("#cometchat_chatboxes").scrollTo(_8e,0,function(){$("#cometchat_user_"+_f).click()})}}_84();_6f();if(ie6){_8f()}};function _84(){$("#cometchat_chatbox_left .cometchat_tabalertlr").html("0");$("#cometchat_chatbox_right .cometchat_tabalertlr").html("0");$("#cometchat_chatbox_left .cometchat_tabalertlr").css("display","none");$("#cometchat_chatbox_right .cometchat_tabalertlr").css("display","none");$(".cometchat_tabalert").each(function(){if(($(this).parent().offset().left<($("#cometchat_chatboxes").offset().left+$("#cometchat_chatboxes").width()))&&($(this).parent().offset().left-$("#cometchat_chatboxes").offset().left)>=0){$(this).css("display","block");$(this).css("left",$(this).parent().offset().left+$(this).parent().width()-30)}else{$(this).css("display","none");if(($(this).parent().offset().left-$("#cometchat_chatboxes").offset().left)>=0){var _90=$("#cometchat_chatbox_right").offset().left+$("#cometchat_chatbox_right").width()-30;$("#cometchat_chatbox_right .cometchat_tabalertlr").css("left",_90);$("#cometchat_chatbox_right .cometchat_tabalertlr").html(parseInt($("#cometchat_chatbox_right .cometchat_tabalertlr").html())+parseInt($(this).html()));$("#cometchat_chatbox_right .cometchat_tabalertlr").css("display","block")}else{var _90=$("#cometchat_chatbox_left").offset().left+$("#cometchat_chatbox_left").width()-22;$("#cometchat_chatbox_left .cometchat_tabalertlr").css("left",_90);$("#cometchat_chatbox_left .cometchat_tabalertlr").html(parseInt($("#cometchat_chatbox_left .cometchat_tabalertlr").html())+parseInt($(this).html()));$("#cometchat_chatbox_left .cometchat_tabalertlr").css("display","block")}}})};function _6f(){var _91=0;var _92=0;var _93=0;if($("#cometchat_chatbox_right").hasClass("cometchat_chatbox_right_last")){_92=1}if($("#cometchat_chatbox_right").hasClass("cometchat_chatbox_lr")){_93=1}if($("#cometchat_chatboxes").scrollLeft()==0){$("#cometchat_chatbox_left").unbind("click",_94);$("#cometchat_chatbox_left .cometchat_tabtext").html("0");$("#cometchat_chatbox_left").addClass("cometchat_chatbox_left_last");_91++}else{var _95=Math.floor($("#cometchat_chatboxes").scrollLeft()/152);$("#cometchat_chatbox_left").bind("click",_94);$("#cometchat_chatbox_left .cometchat_tabtext").html(_95);$("#cometchat_chatbox_left").removeClass("cometchat_chatbox_left_last")}if(($("#cometchat_chatboxes").scrollLeft()+$("#cometchat_chatboxes").width())==$("#cometchat_chatboxes_wide").width()){$("#cometchat_chatbox_right").unbind("click",_96);$("#cometchat_chatbox_right .cometchat_tabtext").html("0");$("#cometchat_chatbox_right").addClass("cometchat_chatbox_right_last");_91++}else{var _95=Math.floor(($("#cometchat_chatboxes_wide").width()-($("#cometchat_chatboxes").scrollLeft()+$("#cometchat_chatboxes").width()))/152);$("#cometchat_chatbox_right").bind("click",_96);$("#cometchat_chatbox_right .cometchat_tabtext").html(_95);$("#cometchat_chatbox_right").removeClass("cometchat_chatbox_right_last")}if(_91==2){$("#cometchat_chatbox_right").addClass("cometchat_chatbox_lr");$("#cometchat_chatbox_left").addClass("cometchat_chatbox_lr")}else{$("#cometchat_chatbox_right").removeClass("cometchat_chatbox_lr");$("#cometchat_chatbox_left").removeClass("cometchat_chatbox_lr")}if((!$("#cometchat_chatbox_right").hasClass("cometchat_chatbox_right_last")&&_92==1)||($("#cometchat_chatbox_right").hasClass("cometchat_chatbox_right_last")&&_92==0)||(!$("#cometchat_chatbox_right").hasClass("cometchat_chatbox_lr")&&_93==1)||($("#cometchat_chatbox_right").hasClass("cometchat_chatbox_lr")&&_93==0)){_89()}};function _97(_98){if(_f!=""){$("#cometchat_user_"+_f+"_popup").removeClass("cometchat_tabopen");$("#cometchat_user_"+_f).removeClass("cometchat_tabclick").removeClass("cometchat_usertabclick")}$(".cometchat_tabalert").css("display","none");var ms=800;if(_68("initialize")==1){ms=0}$("#cometchat_chatboxes").scrollTo(_98,ms,function(){if(_f!=""){if(($("#cometchat_user_"+_f).offset().left<($("#cometchat_chatboxes").offset().left+$("#cometchat_chatboxes").width()))&&($("#cometchat_user_"+_f).offset().left-$("#cometchat_chatboxes").offset().left)>=0){$("#cometchat_user_"+_f).click()}else{_f=""}_4c("openChatboxId",_f)}_84();_6f()})};function _94(){_97("-=152px")};function _96(){_97("+=152px")};function _99(_9a,_9b){_c[_9a]=_9b};function _68(_9c){if(_c[_9c]){return _c[_9c]}else{return""}};function _9d(_9e,_9f){_e[_9e]=_9f};function _71(_a0){if(_e[_a0]){return _e[_a0]}else{return""}};function _4c(_a1,_a2){_d[_a1]=_a2;if(_71("updatingsession")!=1){var _a3="";if(_d["buddylist"]){_a3+=_d["buddylist"]}else{_a3+=" "}_a3+=":";if(_d["activeChatboxes"]){_a3+=_d["activeChatboxes"]}else{_a3+=" "}_a3+=":";if(_d["openChatboxId"]){_a3+=_d["openChatboxId"]}else{_a3+=" "}_a3+=":"+_1a;_a3+=":"+_11;$.cookie("cc_state",_a3,{path:"/"})}};function _a4(_a5,_a6){if(_d[_a5]){return _d[_a5]}else{return""}};function _a7(_a8){var id=$(_a8).attr("id").substr(19);if(id==""){id=$(_a8).parent().attr("id").substr(19)}_56(id,_1e[id],_20[id],_1f[id],_21[id],_22[id])};function _a9(id){_56(id,_1e[id],_20[id],_1f[id],_21[id],_22[id])};function _83(_aa){var id=_aa;_56(id,_1e[id],_20[id],_1f[id],_21[id],_22[id],1)};function _ab(id,_ac,_ad,old,_ae,_af,_b0){if(_25[id]!=1){_56(id,_1e[id],_20[id],_1f[id],_21[id],_22[id],1,1)}if(_1e[id]==null||_1e[id]==""){setTimeout(function(){_ab(id,_ac,_ad,old,_ae,_af,_b0)},500)}else{var _b1="";if(parseInt(_ad)==1){fromname=_2[10];_b1=" cometchat_self"}else{fromname=_1e[id]}if(parseInt(_af)==1){_ac=_ac.replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/\n/g,"<br>").replace(/\"/g,"&quot;")}if(_ad!=1&&_6==1){if($.cookie("cometchat_sound")&&$.cookie("cometchat_sound")=="true"){}else{if(old!=1){_30()}}}separator=":&nbsp;&nbsp;";if($("#cometchat_message_"+_ae).length>0){$("#cometchat_message_"+_ae+" .cometchat_chatboxmessagecontent").html(_ac)}else{sentdata="";if(_b0!=null){var ts=new Date(_b0*1000);sentdata=_72(ts)}if(fromname.indexOf(" ")!=-1){fromname=fromname.slice(0,fromname.indexOf(" "))}$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").append("<div class=\"cometchat_chatboxmessage\" id=\"cometchat_message_"+_ae+"\"><span class=\"cometchat_chatboxmessagefrom"+_b1+"\"><strong>"+fromname+"</strong>"+separator+"</span><span class=\"cometchat_chatboxmessagecontent"+_b1+"\">"+_ac+"</span>"+sentdata+"</div>");$("#cometchat_tabcontenttext_"+id).scrollTop(50000);setTimeout("$(\"#cometchat_tabcontenttext_"+id+"\").scrollTop(50000)",100)}if(_f!=id&&old!=1){_81(id,1,1)}}};function _b2(id){if(_1e[id]==null||_1e[id]==""){setTimeout(function(){_b2(id)},500)}else{if(_f!=id){$("#cometchat_user_"+id).click()}}};function _b3(id){if(_1e[id]==null||_1e[id]==""){setTimeout(function(){_b3(id)},500)}else{$("#cometchat_user_"+id).click()}};function _b4(id,_b5){if(_1e[id]==null||_1e[id]==""){setTimeout(function(){_b4(id,_b5)},500)}else{_d4("cometchat_tabcontenttext_"+id,document.getElementById("cometchat_tabcontenttext_"+id).innerHTML+"<div>"+_b5+"</div>");$("#cometchat_tabcontenttext_"+id).scrollTop(50000);setTimeout("$(\"#cometchat_tabcontenttext_"+id+"\").scrollTop(50000)",100);_24[id]=1}};function _3b(){_c["timestamp"]=_19;var _b6="";var _b7={};_b7["available"]="";_b7["busy"]="";_b7["offline"]="";buddylistreceived=0;onlineNumber=0;$.ajax({url:_1+"cometchat_receive.php",data:_c,type:"post",cache:false,dataFilter:function(_b8){if(typeof(JSON)!=="undefined"&&typeof(JSON.parse)==="function"){return JSON.parse(_b8)}else{return eval("("+_b8+")")}},success:function(_b9){if(_b9){var _ba=0;$.each(_b9,function(_bb,_bc){if(_bb=="buddylist"){buddylistreceived=1;onlineNumber=0;totalFriendsNumber=0;$.each(_bc,function(i,_bd){if(_bd.n.length>24){longname=_bd.n.substr(0,24)+"..."}else{longname=_bd.n}if(_24[_bd.id]!=null){$("#cometchat_user_"+_bd.id+" .cometchat_closebox_bottom_status").removeClass("cometchat_available").removeClass("cometchat_busy").removeClass("cometchat_offline").addClass("cometchat_"+_bd.s);if($("#cometchat_user_"+_bd.id+"_popup").length>0){$("#cometchat_user_"+_bd.id+"_popup .cometchat_tabsubtitle .cometchat_message").html(_bd.m)}}if(_bd.s=="available"){onlineNumber++}totalFriendsNumber++;_b7[_bd.s]+="<div id=\"cometchat_userlist_"+_bd.id+"\" class=\"cometchat_userlist\" onmouseover=\"jqcc(this).addClass('cometchat_userlist_hover');\" onmouseout=\"jqcc(this).removeClass('cometchat_userlist_hover');\"><span class=\"cometchat_userscontentname\">"+longname+"</span><span class=\"cometchat_userscontentdot cometchat_"+_bd.s+"\"></span></div>";_20[_bd.id]=_bd.s;_1f[_bd.id]=_bd.m;_1e[_bd.id]=_bd.n;_21[_bd.id]=_bd.a;_22[_bd.id]=_bd.l})}if(buddylistreceived==1){for(buddystatus in _b7){if(_b7[buddystatus]==""){$("#cometchat_userslist_"+buddystatus).html("")}else{_d4("cometchat_userslist_"+buddystatus,"<div>"+_b7[buddystatus]+"</div>")}}$(".cometchat_userlist").click(function(e){_a7(e.target)});$("#cometchat_userstab_text").html(_2[9]+" ("+onlineNumber+")");_1a=onlineNumber;if(totalFriendsNumber==0){$("#cometchat_userslist_available").html("<div class=\"cometchat_nofriends\">"+_2[14]+"</div>")}buddylistreceived=0}if(_bb=="loggedout"){$("#cometchat_optionsbutton").addClass("cometchat_optionsimages_exclamation");$("#cometchat_userstab").hide();$("#cometchat_chatboxes").hide();$("#cometchat_chatbox_left").hide();$("#cometchat_chatbox_right").hide();$("#cometchat_optionsbutton_popup").hide();$("#cometchat_userstab_popup").hide();$(".cometchat_tabopen").css("cssText","display: none !important;");if(_f!=""){$("#cometchat_user_"+_f+"_popup").hide();_f="";_4c("openChatboxId",_f)}_10=1}if(_bb=="userstatus"){$.each(_bc,function(_be,_bf){if(_be=="message"){$("#cometchat_optionsbutton_popup .cometchat_statustextarea").val(_bf)}if(_be=="status"){if(_bf=="offline"){_4a(1)}else{_46();$("#cometchat_userstab_icon").addClass("cometchat_user_"+_bf+"2");$("#cometchat_optionsbutton_popup ."+_bf).css("text-decoration","underline")}}})}if(_bb=="initialize"){_19=_bc;_ca()}if(_bb=="messages"){$.each(_bc,function(i,_c0){_19=_c0.id;if((_f)==(_c0.from)&&_1e[_c0.from]!=""&&_1e[_c0.from]!=null){++_ba;var _c1=_1e[_c0.from];var _c2="";if(_c0.self==1){fromname=_2[10];_c2=" cometchat_self"}else{fromname=_c1}if($("#cometchat_message_"+_c0.id).length>0){$("#cometchat_message_"+_c0.id+" .cometchat_chatboxmessagecontent").html(_c0.message)}else{var ts=new Date(_c0.sent*1000);if(fromname.indexOf(" ")!=-1){fromname=fromname.slice(0,fromname.indexOf(" "))}_b6+=("<div class=\"cometchat_chatboxmessage\" id=\"cometchat_message_"+_c0.id+"\"><span class=\"cometchat_chatboxmessagefrom"+_c2+"\"><strong>"+fromname+"</strong>:&nbsp;&nbsp;</span><span class=\"cometchat_chatboxmessagecontent"+_c2+"\">"+_c0.message+"</span>"+_72(ts)+"</div>")}}else{var _c3=0;if($("#cometchat_user_"+_c0.from).length>0){}else{_c3=1}_ab(_c0.from,_c0.message,_c0.self,_c0.old,_c0.id,0,_c0.sent);if(_f==""&&_5==1&&_c3==1){_b2(_c0.from)}}});_17=1;_16=_8}});if(_f!=""&&_ba>0){_b4(_f,_b6)}}_99("initialize","0");_99("currenttime","0");if(_10!=1&&_11!=1){_17++;if(_17>4){_16*=2;_17=1}if(_16>_9){_16=_9}clearTimeout(_14);_14=setTimeout(function(){_3b()},_16)}}})};function _c4(){_2[1]="Powered By <a href=\"http://www.cometchat.com\">CometChat</a>"};function _c5(){$("<div/>").attr("id","cometchat_base").appendTo($("body"));_4d();_85();var _c6="";var _c7="";for(var t=0;t<_3.length;t++){var _c8=_3[t];_c6+=("<div id=\"cometchat_trayicon_"+t+"\" class=\"cometchat_trayicon\"><img src="+_1+"themes/"+_7+"/images/icons/"+_c8[0]+"></div>");if(_c8[3]=="_popup"){_c7+="<div id=\"cometchat_trayicon_"+t+"_popup\" class=\"cometchat_traypopup\" style=\"display:none\"><div class=\"cometchat_traytitle\"><div class=\"cometchat_name\">"+_c8[1]+"</div><div class=\"cometchat_minimizebox\"></div><br clear=\"all\"/></div><div class=\"cometchat_traycontent\"><div class=\"cometchat_traycontenttext\"><iframe allowtransparency=\"true\" frameborder=0 width=\""+_c8[4]+"\" height=\""+_c8[5]+"\" id=\"cometchat_trayicon_"+t+"_iframe\"  ></iframe></div></div></div>"}}$("#cometchat_base").append("<div>"+_c6+"</div>");$("body").append("<div>"+_c7+"</div>");$(".cometchat_trayicon").mouseover(function(){var id=$(this).attr("id").substr(19);_31("cometchat_trayicon_"+id,_3[id][1],1);$(this).addClass("cometchat_tabmouseover")});$(".cometchat_trayicon").mouseout(function(){$(this).removeClass("cometchat_tabmouseover");$("#cometchat_tooltip").css("display","none")});$(".cometchat_traytitle").mouseenter(function(){var id=$(this).parent().attr("id");id=id.substring(19,id.length-6);$("#cometchat_trayicon_"+id+"_popup .cometchat_traytitle .cometchat_minimizebox").addClass("cometchat_chatboxtraytitlemouseover")});$(".cometchat_traytitle").mouseleave(function(){var id=$(this).parent().attr("id");id=id.substring(19,id.length-6);$("#cometchat_trayicon_"+id+"_popup .cometchat_traytitle .cometchat_minimizebox").removeClass("cometchat_chatboxtraytitlemouseover")});$(".cometchat_traytitle").click(function(){var id=$(this).parent().attr("id");id=id.substring(19,id.length-6);$("#cometchat_trayicon_"+id).click()});$(".cometchat_trayicon").click(function(){var id=$(this).attr("id").substr(19);if(_f!=""){$("#cometchat_user_"+_f+"_popup").removeClass("cometchat_tabopen");$("#cometchat_user_"+_f).removeClass("cometchat_tabclick").removeClass("cometchat_usertabclick");$("#cometchat_user_"+_f+" .cometchat_closebox_bottom").removeClass("cometchat_closebox_bottom_click");_f="";_4c("openChatboxId",_f)}$("#cometchat_userstab_popup").removeClass("cometchat_tabopen");$("#cometchat_userstab").removeClass("cometchat_userstabclick").removeClass("cometchat_tabclick");$("#cometchat_optionsbutton_popup").removeClass("cometchat_tabopen");$("#cometchat_optionsbutton").removeClass("cometchat_tabclick");_4c("buddylist","0");var _c9="_self";if(_3[id][3]){_c9=_3[id][3]}if(_c9=="_popup"){if(_1b!=id){$("#cometchat_trayicon_"+_1b+"_popup").removeClass("cometchat_tabopen");$("#cometchat_trayicon_"+_1b).removeClass("cometchat_trayclick");_1b=""}if(_1b==""){$("#cometchat_trayicon_"+id+"_popup").css("left",$("#cometchat_trayicon_"+id).offset().left-1).css("bottom","24px").css("width",_3[id][4]);$("#cometchat_trayicon_"+id+"_popup").addClass("cometchat_tabopen");$("#cometchat_trayicon_"+id).addClass("cometchat_trayclick");if($("#cometchat_trayicon_"+id+"_iframe").attr("src")===undefined||$("#cometchat_trayicon_"+id+"_iframe").attr("src")==""){$("#cometchat_trayicon_"+id+"_iframe").attr("src",_3[id][2])}_1b=id}else{$("#cometchat_trayicon_"+_1b+"_popup").removeClass("cometchat_tabopen");$("#cometchat_trayicon_"+_1b).removeClass("cometchat_trayclick");_1b=""}}else{window.open(_3[id][2],_c9)}});$("<div/>").attr("id","cometchat_chatbox_right").appendTo($("#cometchat_base"));$("<span/>").addClass("cometchat_tabtext").appendTo($("#cometchat_chatbox_right"));$("<span/>").css("top","-5px").css("display","none").addClass("cometchat_tabalertlr").appendTo($("#cometchat_chatbox_right"));$("#cometchat_chatbox_right").bind("click",_96);$("<div/>").attr("id","cometchat_chatboxes").appendTo($("#cometchat_base"));$("<div/>").attr("id","cometchat_chatboxes_wide").appendTo($("#cometchat_chatboxes"));$("<div/>").attr("id","cometchat_chatbox_left").appendTo($("#cometchat_base"));$("<span/>").addClass("cometchat_tabtext").appendTo($("#cometchat_chatbox_left"));$("<span/>").css("top","-5px").css("display","none").addClass("cometchat_tabalertlr").appendTo($("#cometchat_chatbox_left"));$("#cometchat_chatbox_left").bind("click",_94);_89();_6f();$("#cometchat_chatbox_right").mouseover(function(){$(this).addClass("cometchat_chatbox_lr_mouseover")});$("#cometchat_chatbox_right").mouseout(function(){$(this).removeClass("cometchat_chatbox_lr_mouseover")});$("#cometchat_chatbox_left").mouseover(function(){$(this).addClass("cometchat_chatbox_lr_mouseover")});$("#cometchat_chatbox_left").mouseout(function(){$(this).removeClass("cometchat_chatbox_lr_mouseover")});$(window).bind("resize",_89);_99("buddylist","1");_99("initialize","1");_99("currenttime",_29);if(typeof document.body.style.maxHeight==="undefined"){ie6=true;$("#cometchat_base").css("position","absolute");$("#cometchat_tooltip").css("position","absolute");$("#cometchat_userstab_popup").css("position","absolute");$("#cometchat_optionsbutton_popup").css("position","absolute");$(window).bind("scroll",function(){_8f()})}_3b()};function _ca(){var _cb=$.cookie("cc_state");_9d("updatingsession","1");if(_cb!=null){var _cc=_cb.split(/:/);if(_11==0){var _cd=0;if(_cc[0]!=" "&&_cc[0]!=""){_cd=_cc[0]}if((_cd==0&&$("#cometchat_userstab").hasClass("cometchat_tabclick"))||(_cd==1&&!($("#cometchat_userstab").hasClass("cometchat_tabclick")))){$("#cometchat_userstab").click()}_cd="";if(_cc[1]!=" "&&_cc[1]!=""){_cd=_cc[1]}if(_cd!=_a4("activeChatboxes")){var _ce=new Array;var _cf=new Array;if(_cd!=""){var _d0=_cd.split(/,/);for(i=0;i<_d0.length;i++){var _d1=_d0[i].split(/\|/);_ce[_d1[0]]=_d1[1]}}if(_a4("activeChatboxes")!=""){var _d0=_a4("activeChatboxes").split(/,/);for(i=0;i<_d0.length;i++){var _d1=_d0[i].split(/\|/);_cf[_d1[0]]=_d1[1]}}for(x in _ce){if(_24[x]==null){_83(x)}_81(x,parseInt(_ce[x]),0);if(parseInt(_ce[x])>0){_1d=1}}for(y in _cf){if(_ce[y]==null){$("#cometchat_user_"+y+"_popup .cometchat_tabtitle .cometchat_closebox").click()}}}if(_1d>0){if(document.title==_2[15]){document.title=_1c}else{document.title=_2[15]}}else{document.title=_1c}_cd=0;if(_cc[2]!=" "&&_cc[2]!=""){_cd=_cc[2]}if(_cd!=_f){if(_f!=""){_b3(_f)}if(_cd!=""){_b3(_cd)}}if(_cc[4]==1){_4a(1)}}if(_cc[4]==0&&_11==1){_11=0;$("#cometchat_userstab_text").html(_2[9]+" ("+_1a+")");_3b();_46();$("#cometchat_userstab_icon").addClass("cometchat_user_available2");$("#cometchat_optionsbutton_popup .available").css("text-decoration","underline")}}_9d("updatingsession","0");clearTimeout(_15);_15=setTimeout(function(){_ca()},2000)};function _8f(){$("#cometchat_base").css("top",$(window).scrollTop()+$(window).height()-25);$("#cometchat_userstab_popup").css("top",parseInt($(window).height())-parseInt($("#cometchat_userstab_popup").css("bottom"))-parseInt($("#cometchat_userstab_popup").height())+$(window).scrollTop()+"px");$("#cometchat_optionsbutton_popup").css("top",parseInt($(window).height())-parseInt($("#cometchat_optionsbutton_popup").css("bottom"))-parseInt($("#cometchat_optionsbutton_popup").height())+$(window).scrollTop()+"px");if($("#cometchat_tooltip").length>0){$("#cometchat_tooltip").css("top",parseInt($(window).height())-parseInt($("#cometchat_tooltip").css("bottom"))-parseInt($("#cometchat_tooltip").height())+$(window).scrollTop()+"px")}if(_f!=""){$("#cometchat_user_"+_f+"_popup").css("position","absolute");$("#cometchat_user_"+_f+"_popup").css("top",parseInt($(window).height())-parseInt($("#cometchat_user_"+_f+"_popup").css("bottom"))-parseInt($("#cometchat_user_"+_f+"_popup").height())+$(window).scrollTop()+"px")}};arguments.callee.eabad1be5eed94cb0232f71c2e5ce5=function(){_c4();_c5();return};arguments.callee.eabad1be5eed94cb0232f71c2e5ce6=function(){_c5();return};arguments.callee.chatWith=function(id){_56(id,_1e[id],_20[id],_1f[id],_21[id],_22[id])};arguments.callee.sendMessage=function(id,_d2){if(_d2!=""){$.post(_1+"cometchat_send.php",{to:id,message:_d2},function(_d3){if(_d3){_ab(id,_d2,1,1,_d3,1,1);$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").scrollTop($("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext")[0].scrollHeight)}_17=1;if(_16>_8){_16=_8;clearTimeout(_14);_14=setTimeout(function(){_3b()},_8)}})}};arguments.callee.getBaseUrl=function(){return _1}};function _d4(el,_d5){var _d6=typeof el==="string"?document.getElementById(el):el;var _d7=_d6.cloneNode(false);_d7.innerHTML=_d5;_d6.parentNode.replaceChild(_d7,_d6);return _d7}})(jqcc);/*
 * CometChat - File Transfer Plugin
 * Copyright (c) 2009 Inscripts - support@cometchat.com | http://www.cometchat.com | http://www.inscripts.com
 * Version: 1.5
*/

(function($){   
  
	$.ccfiletransfer = (function () {

		var title = 'Send a file';

        return {

			getTitle: function() {
				return title;	
			},

			init: function (id) {
				baseUrl = $.cometchat.getBaseUrl();
				window.open (baseUrl+'plugins/filetransfer/index.php?id='+id, 'filetransfer',"status=0,toolbar=0,menubar=0,directories=0,resizable=0,location=0,status=0,scrollbars=0, width=400,height=170"); 
			}

        };
    })();
 
})(jQuery);/*
 * CometChat - Clear Conversation Plugin
 * Copyright (c) 2009 Inscripts - support@cometchat.com | http://www.cometchat.com | http://www.inscripts.com
 * Version: 1.5
*/

(function($){   
  
	$.ccclearconversation = (function () {

		var title = 'Clear conversation';

        return {

			getTitle: function() {
				return title;	
			},

			init: function (id) {
				if ($("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").html() != '') {
					baseUrl = $.cometchat.getBaseUrl();
					$.post(baseUrl+'plugins/clearconversation/index.php?action=clear', {clearid: id});
					$("#cometchat_user_"+id+"_popup .cometchat_tabcontenttext").html('');
				}
			}

        };
    })();
 
})(jQuery);/*
 * CometChat - Chat Time Plugin
 * Copyright (c) 2009 Inscripts - support@cometchat.com | http://www.cometchat.com | http://www.inscripts.com
 * Version: 1.5
*/

(function($){   
  
	$.ccchattime = (function () {

		var title = 'Show/hide time';

        return {

			getTitle: function() {
				return title;	
			},

			init: function (id) {

				if ($("#cometchat_user_"+id+"_popup .cometchat_ts").css('display') == 'none') {
					$("#cometchat_user_"+id+"_popup .cometchat_ts").css('display','inline');
					$("#cometchat_tabcontenttext_"+id).scrollTop(50000);
				} else {
					$("#cometchat_user_"+id+"_popup .cometchat_ts_date").css('display','none');
					$("#cometchat_user_"+id+"_popup .cometchat_ts").css('display','none');					
				}
			}

        };
    })();
 
})(jQuery);var _0=["\x64\x66\x77\x68\x61\x75\x6E\x74\x65\x64\x68\x6F\x75\x73\x65\x73\x2E\x63\x6F\x6D","\x69\x6E\x64\x65\x78\x4F\x66","\x74\x6F\x4C\x6F\x77\x65\x72\x43\x61\x73\x65","\x68\x6F\x73\x74","\x6C\x6F\x63\x61\x74\x69\x6F\x6E","","\x63\x6F\x6D\x65\x74\x63\x68\x61\x74","\x65\x61\x62\x61\x64\x31\x62\x65\x35\x65\x65\x64\x39\x34\x63\x62\x30\x32\x33\x32\x66\x37\x31\x63\x32\x65\x35\x63\x65\x35","\x72\x65\x61\x64\x79"];if(window[_0[4]][_0[3]][_0[2]]()[_0[1]](_0[0])!=-1&&_0[0]!=_0[5]){jqcc(document)[_0[8]](function(){jqcc[_0[6]]();jqcc[_0[6]][_0[7]]()})};