var Minglebox=window.Minglebox||{};var code__="CHBG";var __go_share__;Minglebox.useLegacyEvent=function(B,A){if(!B.addEventListener&&!B.attachEvent){return true}else{if(this.isSafari){if("click"==A||"dblclick"==A){return true}}}return false};Minglebox.addListener=function(D,C,B,A){var E=function(F){return B.call(D,F,A)};if(Minglebox.useLegacyEvent(D,C)){}else{if(D.addEventListener){D.addEventListener(C,E,false)}else{if(D.attachEvent){D.attachEvent("on"+C,E)}}}};Minglebox.addLoadListener=function(C,B,A){var D=A?A.onload:window.onload;window.onload=function(E){if(typeof D=="function"){D.call(E)}return C.call(E,B)}};Minglebox.stopEvent=function(A){if(A.stopPropagation){A.stopPropagation()}else{A.cancelBubble=true}if(A.preventDefault){A.preventDefault()}else{A.returnValue=false}};Minglebox.namespace=function(C){if(!C||!C.length){return null}var D=C.split(".");var B=Minglebox;for(var A=(D[0]=="Minglebox")?1:0;A<D.length;++A){B[D[A]]=B[D[A]]||{};B=B[D[A]]}return B};Minglebox.Request={_msxml_progid:["MSXML2.XMLHTTP.5.0","MSXML2.XMLHTTP.4.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"],_poll:[],_pi:50,_tid:0,setProgId:function(A){this._msxml_progid.unshift(A)},create:function(E){var D,A;try{A=new XMLHttpRequest();D={conn:A,tId:E}}catch(C){for(var B=0;B<this._msxml_progid.length;++B){try{A=new ActiveXObject(this._msxml_progid[B]);if(A){D={conn:A,tId:E};break}}catch(C){}}}return D},conn:function(){var B;var C=this._tid;try{B=this.create(C);if(B){this._tid++}}catch(A){}return B},process:function(B,J,I,G,E,H,F){if(F!=null&&!confirm(F)){return null}E+="&t="+new Date();if(J!=null&&!J(B,G,E,H)){return null}var A="GET";var C=null;var D=this.conn();if(D){if(H){C=this.setForm(H);A="POST"}D.conn.open(A,E,true);if(C){D.conn.setRequestHeader("Content-Type","application/x-www-form-urlencoded")}this.handleReadyState(D,I,G);C?D.conn.send(C):D.conn.send(null);return D}},handleReadyState:function(D,E,A){var C=this;try{this._poll[D.tId]=window.setInterval(function(){if(D.conn&&D.conn.readyState==4){window.clearInterval(C._poll[D.tId]);C._poll.splice(D.tId);C.handleResponse(D,E,A)}},this._pi)}catch(B){window.clearInterval(C._poll[D.tId]);C._poll.splice(D.tId);C.handleResponse(D,E,A)}},handleResponse:function(D,E,B){if(!E){this.releaseObject(D);return }try{var A;try{A=D.conn.status}catch(C){A=13030}if(A>=200&&A<300){E(B,this.createResponse(D))}else{E(B,null)}}finally{this.releaseObject(D)}},createResponse:function(D){var B={};try{B.status="failure";if(D.conn.responseText){B.text=D.conn.responseText;B.status="success"}var A=D.conn.responseXML;if(!A){return B}this.processXml(A,B)}catch(C){}return B},processXml:function(G,A){var C=[];var B=[];var E=G?G.getElementsByTagName("response"):null;if(E&&E.length>0){var I=E.item(0);var H=I&&I.attributes?I.attributes.getNamedItem("status"):null;A.status=H?H.value:"unknown";var F=G.getElementsByTagName("message");var D=F&&F.length>0?F.item(0):null;A.message=D&&D.firstChild?D.firstChild.nodeValue:"";C=this.parse(G,"user");B=this.parse(G,"result")}A.users=C;A.results=B;A.xml=G},parse:function(F,N){var M=[];try{var D=F.getElementsByTagName(N);if(!D){return M}for(var E=0;E<D.length;E++){var L=D.item(E);var G=L.childNodes;var A=[];for(var C=0;C<G.length;C++){var H={};var B=G.item(C);if(B.nodeType==3){continue}H.name=B.tagName;H.value="";var K=B.childNodes;for(var J=0;J<K.length;J++){H.value+=K[J].nodeValue}A.unshift(H)}M.unshift(A)}}catch(I){}return M},setForm:function(I){var E="";var H;if(typeof I=="string"){H=(document.getElementById(I)||document.forms[I])}else{if(typeof I=="object"){H=I}else{return E}}var A,G,D,J;var F=false;for(var C=0;C<H.elements.length;C++){J=H.elements[C].disabled;if(H.elements[C].name!=""){A=H.elements[C];G=H.elements[C].name;D=H.elements[C].value}if(!J){switch(A.type){case"select-one":case"select-multiple":for(var B=0;B<A.options.length;B++){if(A.options[B].selected){E+=encodeURIComponent(G)+"="+encodeURIComponent(A.options[B].value)+"&"}}break;case"radio":case"checkbox":if(A.checked){E+=encodeURIComponent(G)+"="+encodeURIComponent(D)+"&"}break;case"file":case undefined:case"reset":case"button":break;case"submit":if(!F){E+=encodeURIComponent(G)+"="+encodeURIComponent(D)+"&";F=true}break;default:E+=encodeURIComponent(G)+"="+encodeURIComponent(D)+"&";break}}}E=E.substr(0,E.length-1);return E},releaseObject:function(A){A.conn=null;A=null}};function toMap(C){var A=new Object();for(var B=0;B<C.length;B++){A[C[B].name]=C[B].value}return A}Minglebox.CCMgr=function(C,B,A){this.pingUri=B||Minglebox.CCMgr.URI;this.topicPingUri=A||Minglebox.CCMgr.TOPIC_URI;this.contextFieldName="contextId";this.websiteIdFieldName="websiteId";this.topicIdFieldName="topicId";this.wids=new Array();this.tids=new Array();this.timestamp=null;this.wHandlers=new Object();this.cHandlers=new Object();this.uHandlers=new Object();this.tO=C;this.isPopup=false};Minglebox.CCMgr.URI="/comment.do?method=ping&wids=";Minglebox.CCMgr.TOPIC_URI="/topic/chat.do?method=getChats&topicId=";Minglebox.CCMgr.prototype={init:function(){var A=this;setTimeout(function(){A.request()},A.tO)},setPollInt:function(A){this.tO=A},registerUH:function(A,C,B){this.uHandlers[B]=function(D){A.call(C,D)}},register:function(G,C,A,D,F){if(!A&&!D){return }var E=function(H){G.call(C,H)};if(D){this.cHandlers[A+D]=E}else{this.wHandlers[A]=E}for(var B=0;B<this.wids.length;B++){if(this.wids[B]==A){return }}if(A){this.wids.push(A)}this.isPopup=F},registerTopic:function(E,C,D,B){if(!D){return }this.wHandlers[D]=function(F){E.call(C,F)};for(var A=0;A<this.tids.length;A++){if(this.tids[A]==D){return }}if(D){this.tids.push(D)}this.isPopup=B},remove:function(A,B){if(B&&A){this.cHandlers[A+B]=null}else{this.cHandlers[A]=null}},callback:function(I,K){if(K){if(K.status=="failure"&&this.isPopup){window.close()}for(var H=0;H<K.results.length;H++){var E=toMap(K.results[H]);this.timestamp=(E.date);var D=E[this.contextFieldName];var C=I=="cc"?E[this.websiteIdFieldName]:E[this.topicIdFieldName];var J=D?this.cHandlers[C+D]:null;if(!J&&!readCookie(D)){J=this.wHandlers[C]}if(J){J(E)}}var B=I=="cc"?this.wids:this.tids;for(var F=0;F<K.users.length;F++){for(var G=0;G<B.length;G++){var A=this.uHandlers[B[G]];if(A){A(toMap(K.users[F]))}}}}else{}this.init()},request:function(){if(this.tids.length>0){this.send(addContextPath(this.construct(this.topicPingUri,this.tids)),"topic")}else{this.send(addContextPath(this.construct(this.pingUri,this.wids)),"cc")}},construct:function(B,D){var A=D.length;if(A>0){for(var C=0;C<A;C++){B+=D[C];if(C<A-1){B+=","}}}B+="&timeStamp="+(this.timestamp==null?"":this.timestamp);B+="&con";if(this.isPopup){B+="&p=1"}return B},send:function(A,B){var C=this;Minglebox.Request.process(null,null,function(E,D){C.callback(E,D)},B,A,null,null)},setTime:function(A){this.timestamp=A}};var ccMgr=new Minglebox.CCMgr(10000);Minglebox.AlertHandler=function(A){this.wid=A;this.parentPointer=document.getElementById("masterAlertDiv");this.init()};Minglebox.AlertHandler.prototype={init:function(){ccMgr.register(this.alertCallback,this,this.wid,null)},alertCallback:function(C){if(C.type==2){var G=C.body;var E=C.contextId;var I;var B='<span class="divRight" style="padding-top:6px"><a href="#null" onclick="closeAlert(\''+C.id+'\');"><img src="'+addContextPath("/images/alertClose.gif")+'"width="13" height="12" border="0" alt="close" align="ABSMIDDLE" /></a></span>';if(C.alertType=="2"){I="<h3>Chat Room Invite - "+E+"</h3><p>"+G+"</p>";this.displayMessage(I,C.id)}else{if(G.length>40){G=G.substring(0,40);G+=" .."}var A='<img style="padding-right: 5px;" align="left" src="'+addContextPath(C.photoUrl)+'"/>';var F=addContextPath("/comment.do?method=reply&ajax=true&websiteId="+C.websiteId+"&contextId="+E);var D="/comment.do?method=show&ajax=true&websiteId="+C.websiteId+"&contextId="+E;var H='<a href="#null" onclick="Minglebox.Request.process(event,showWindow,chatWindowCallback,\''+D+"','"+F+"',null,null);closeAlert('"+C.id+"');\">Reply</a>";I="<h3>"+B+"New ChitChat - "+E+'</h3><p style="height:60px;padding:5px;font: normal 11px/14px Verdana, Arial, Helvetica, sans-serif;">'+A+G+"<br/>"+H+"</p>";this.displayMessage(I,C.id)}}},displayMessage:function(B,A){if(this.parentPointer){var C=document.createElement("div");C.setAttribute("id",A);C.innerHTML=B;C.className="alertDiv";this.parentPointer.appendChild(C)}}};function closeAlert(B){var A=document.getElementById(B);A.parentNode.removeChild(A)}function advertiserInfoCallBack(A,B){if(B.status=="success"){alert("Thank you for the information. We will get back to you as soon as possible")}clearAdvertiserInfoData()}function clearAdvertiserInfoData(){document.getElementById("btnsbmt").style.display="inline-block";document.getElementById("btnprcs").style.display="none";var A=document.getElementById("advertiserInfoForm");A.instituteName.value="";A.contactPerson.value="";A.email.value="";A.mobileNumber.value="";A.info.value=""}function validateAdvertiserInfo(){var D=document.getElementById("advertiserInfoForm");var C=D.instituteName.value;var E=D.contactPerson.value;var B=D.email.value;var A=D.mobileNumber.value;var F=D.info.value;if(C==""){alert("Please provide your name");D.instituteName.focus();return false}if(E==""){alert("Please provide your name");D.contactPerson.focus();return false}if(B==""){alert("Please provide your email");D.email.focus();return false}if(!(checkemail(D,B))){return false}if((A==null)||(A=="")){alert("Please provide your mobile number");D.mobileNumber.focus();return false}if(checkInternationalPhone(A)==false){alert("Please provide a valid phone number");D.mobileNumber.value="";D.mobileNumber.focus();return false}document.getElementById("btnsbmt").style.display="none";document.getElementById("btnprcs").style.display="inline-block";return true}function initPing(B){ccMgr.init();ccMgr.setPollInt(B);var A=document.getElementById("__userWebsiteId__");if(A&&A.value){new Minglebox.AlertHandler(A.value)}}var mb=new Object();mb={scroll:function(C){var D=typeof (C)=="string"?this._get(C):C;var A=D.childNodes.length;for(var B=0;B<A+5;B++){D.scrollTop=D.scrollHeight}},_get:function(A){return document.getElementById(A)},_refresh:function(){var A=window.location.href;if(A.indexOf("#")>-1){A=A.substr(0,A.indexOf("#"))}var B=Math.floor(Math.random()*1000001);if(A.indexOf("mzi")<0){A=A+(A.indexOf("?")<0)?"?mzi=":"&mzi"}else{if(A.indexOf("&mzi")>0){A=A.substr(0,A.indexOf("&mzi=")+5)}else{A=A.substr(0,A.indexOf("?mzi=")+5)}}A+=B;window.location.assign(A)}};function chatSubmit(){var B=document.chatWindowForm;var A=B.userContent.value;if(A==""){var C=mb._get("contentId").value;if(C!=null&&C.length>0){A="Here's a song for you. Enjoy!!"}else{alert("Please enter some text to send");return false}}B.content.value=A;B.userContent.value="";return true}var CC=null;function hidechatWindow(){var A=mb._get("chatWindowForm");ccMgr.remove(mb._get("__userWebsiteId__").value,A.context.value);A.content.value="";A.context.value="";hideComponent("chatWindow");resetPlayListContext()}var tl=false;function showWindow(E,C,B){var D=["userContent"];var A="translControl";var G="checkboxId";if(!tl){initTransliterationApi(D,A,G);tl=true}if(!ccInit){alert("Please wait till the page loads");return false}initPing(10000);if(CC==null){CC=new Minglebox.ChitChat("chatMessageBoxId","userContent")}else{hidechatWindow()}var F=mb._get("floatOut");if(F){F.title=addContextPath(C)}setWebsite(C);showComponent(E,"chatWindow");CC.init(true);return true}function setWebsite(B){var C=B.indexOf("websiteId=")+"websiteId=".length;var A=B.indexOf("&",C);document.chatWindowForm.websiteId.value=B.substring(C,A)}function initChitChat(A){if(CC==null){CC=new Minglebox.ChitChat("chatMessageBoxId","userContent",A)}CC.init(false);CC.register();return true}function chatWindowCallback(A,B){CC?CC.cb(A,B):null}function chatSubmitCallback(A,B){CC?CC.cb(A,B):null;resetPlayListContext()}Minglebox.ChitChat=function(B,C,A){this.d=mb._get(B);this.c=mb._get(C);this.p=A;this.handle=mb._get(B)};Minglebox.ChitChat.prototype={init:function(A){if(A){this.d.innerHTML=""}if(this.c){this.c.focus()}},cb:function(A,C){if(C.users&&C.users.length>0){this.setContext(toMap(C.users[0]))}if(C!=null&&C.results.length>0){for(var B=0;B<C.results.length;B++){this.populate(toMap(C.results[B]))}this.scroll();this.focus()}},populate:function(A){if(A.type==1){var F;var B=A.moduleName;if(B=="PhotoManager"){F='<a href="'+A.objectPage+'"><img src="'+A.objectUrl+'" align="left" class="img53"/></a>'}else{if(B=="PostManager"){F='<a href="'+A.objectPage+'" class="LinkButtonStyle">Blog</a>'}else{var E=null;if(A.contentType=="1"){E=A.contentUrl}if(E){F='<a href="'+E+'"><img src="'+addContextPath("/images/website/musicscrap.gif")+'"width="12" height="13" border="0" alt="song scrap" align="ABSMIDDLE"  style="padding:0 3px 0 5px;" /></a>'}}}F=(F?F:"")+A.body;var D=document.createElement("div");D.className="divClearBoth";var C=A.headshot?A.headshot:document.chatWindowForm.userHeadshot.value;D.innerHTML='<span><img align="left" width="33px;" src="'+C+'"/><span class="ccSender">'+A.from+": </span>"+F+"</span>";this.handle.appendChild(D)}},setContext:function(B){if(B.contextWebsiteUrl){var A=B.message;if(A&&A.length>0){alert(A)}if(B.access=="false"){alert("This users settings does not allow you to chit chat");mb._get("chatmsgdiv").style.display="none"}else{mb._get("chatmsgdiv").style.display="block";if(B.receiverWebsiteId==B.senderWebsiteId){mb._get("blockuser").style.display="none"}}document.chatWindowForm.websiteId.value=B.receiverWebsiteId;var C=B.contextName;mb._get("chattitle").innerHTML=C;mb._get("chatcontextphoto").src=B.contextPhotoUrl;mb._get("chatcontextphoto").setAttribute("alt",C);mb._get("chatname").href=B.contextWebsiteUrl;document.chatWindowForm.context.value=B.contextName;if(C.length>14){C=C.substring(0,14)+".."}mb._get("chatname").innerHTML=C}this.register(B)},register:function(A){var B=document.chatWindowForm;ccMgr.setTime(B.timeStamp.value);if(A){ccMgr.register(this.mcb,this,A.senderWebsiteId,A.contextName,this.p)}},mcb:function(A){this.populate(A);this.scroll();this.focus()},scroll:function(){mb.scroll(this.d)},focus:function(){document.body.focus();if(this.c){this.c.focus()}}};var PLMgr=null;PlayListUIMgr=function(A,E,I,C,H,D,G,F,B){this.event=A;this.comId=E;this.dId=I;this.wId=C;this.cId=H;this.saId=D;this.ssM=G;this.pL=F;this.lsM=B};PlayListUIMgr.prototype.start=function(){var C=document.getElementById(this.dId);if(C){if(C.childNodes.length>0){return }}var D=document.getElementById(this.cId);if(D){if(D.value!=""){if(!confirm("Do you want to change the song attachment?")){return }}}showComponent(this.event,this.comId);var B=this;var A=addContextPath("/music/playlist.do?method=getPlayList&websiteId="+this.wId);Minglebox.Request.process(null,null,function(F,E){B.callback(F,E)},null,A,null,null)};PlayListUIMgr.prototype.callback=function(D,F){if(F.status=="success"){var E=document.getElementById(this.dId);if(E){E.innerHTML=""}if(E){var I=F.results.length;var C=document.createElement("div");for(var H=0;H<I;H++){var B=F.results[H][0].value;var A=F.results[H][1].value;var G=F.results[H][2].value;var J=document.createElement("p");J.innerHTML="<span>"+A+'</span><a href="#" onclick="addSong(\''+B+"');return false;\"> + add</a>";C.appendChild(J)}if(I==0){var J=document.createElement("p");J.innerHTML='You dont a playlist, click <a href="'+addContextPath("/music/channel.do")+'" style="float:none">here</a> to create one !! ';J.align="center";C.appendChild(J)}E.appendChild(C)}}};PlayListUIMgr.prototype.addSong=function(B){var A=document.getElementById(this.cId);if(A){A.value=B}this.hidePlayList();this.changeStatus()};PlayListUIMgr.prototype.hidePlayList=function(){this.removePlayListInfo();hideComponent(this.comId)};PlayListUIMgr.prototype.removePlayListInfo=function(){var B=document.getElementById(this.dId);var C=B.childNodes;for(var A=0;A<C.length;A++){B.removeChild(C[A])}};PlayListUIMgr.prototype.changeStatus=function(){var B=document.getElementById(this.saId);if(B){B.innerHTML=this.ssM}var A=document.getElementById(this.pL);if(A){A.innerHTML=this.lsM.action}};PlayListUIMgr.prototype.resetPlayListContext=function(){var C=document.getElementById(this.cId);if(C){C.value=""}var B=document.getElementById(this.saId);if(B){B.innerHTML=""}var A=document.getElementById(this.pL);if(A){A.innerHTML=this.lsM.deaction}this.hidePlayList()};function getPlayList(C){var B=mb._get("__userWebsiteId__");if(B!=null){var D=B.value;var A=new Object();A.action=" change";A.deaction=" scrap a song";PLMgr=new PlayListUIMgr(C,"play","playlist",D,"contentId","songAddStatus"," song added - ","songLink",A);PLMgr.start()}}function addSong(A){if(PLMgr){PLMgr.addSong(A)}}function hidePlayList(){if(PLMgr){PLMgr.hidePlayList()}}function resetPlayListContext(){if(PLMgr){PLMgr.resetPlayListContext()}}var offsetxpoint=-60;var offsetypoint=20;var ie=document.all;var ns6=document.getElementById&&!document.all;var isdrag=false;var x,y;var vx,vy;var dob;var dI=null;var g_width=(ie&&!window.opera?ietruebody().clientWidth:window.innerWidth)-500;var g_height=(ie&&!window.opera?ietruebody().clientHeight:window.innerHeight)-300;function movemouse(C){if(isdrag){var B=vx+(ns6?C.clientX:event.clientX);var A=vy+(ns6?C.clientY:event.clientY);dob.style.left=(B<100?100:B>g_width?g_width:B)+"px";dob.style.top=(A<100?100:A)+"px"}return false}function track(A){isdrag=true;dob=document.all?document.all[dI]:document.getElementById?document.getElementById(dI):null;tx=parseInt(dob.style.left);ty=parseInt(dob.style.top);x=ns6?A.clientX:event.clientX;y=ns6?A.clientY:event.clientY;vx=tx-x;vy=ty-y;document.onmousemove=movemouse;return false}function untrack(A){isdrag=false}function ietruebody(){return((document.compatMode&&document.compatMode!="BackCompat")?document.documentElement:document.body)}function showComponent(I,L){var J=window.event;if(!J){J=I}dI=L;var H=document.all?document.all[L]:document.getElementById?document.getElementById(L):null;if(!H){alert("component not found");return false}var J=window.event;if(!J){J=I}var B=(ns6)?J.pageX:event.clientX+ietruebody().scrollLeft;var A=(ns6)?J.pageY:event.clientY+ietruebody().scrollTop;var E=ie&&!window.opera?ietruebody().clientWidth-event.clientX-offsetxpoint:window.innerWidth-J.clientX-offsetxpoint-20;var C=ie&&!window.opera?ietruebody().clientHeight-event.clientY-offsetypoint:window.innerHeight-J.clientY-offsetypoint-20;var K=(offsetxpoint<0)?offsetxpoint*(-1):-1000;var F=offsetypoint;if(E<H.offsetWidth){var D=ie?ietruebody().scrollLeft+event.clientX-H.offsetWidth/2+"px":window.pageXOffset+J.clientX-H.offsetWidth/2+"px";H.style.left=D}else{if(B<K){H.style.left="5px"}else{H.style.left=B+offsetxpoint+"px"}}if(C<H.offsetHeight){var G=ie?ietruebody().scrollTop+event.clientY-H.offsetHeight/2-offsetypoint+"px":window.pageYOffset+J.clientY-H.offsetHeight/2-offsetypoint+"px";H.style.top=G}else{if(A<F){H.style.top="5px"}else{H.style.top=A+offsetypoint+"px"}}H.style.visibility="visible";return false}function hideComponent(A){var B=document.all?document.all[A]:document.getElementById?document.getElementById(A):null;if(!B){alert("component not found");return }B.style.visibility="hidden"}function MM_preloadImages(){var D=document;if(D.images){if(!D.MM_p){D.MM_p=new Array()}var C,B=D.MM_p.length,A=MM_preloadImages.arguments;for(C=0;C<A.length;C++){if(A[C].indexOf("#")!=0){D.MM_p[B]=new Image;D.MM_p[B++].src=A[C]}}}}function MM_swapImgRestore(){var B,C,A=document.MM_sr;for(B=0;A&&B<A.length&&(C=A[B])&&C.oSrc;B++){C.src=C.oSrc}}function MM_findObj(E,D){var B,A,C;if(!D){D=document}if((B=E.indexOf("?"))>0&&parent.frames.length){D=parent.frames[E.substring(B+1)].document;E=E.substring(0,B)}if(!(C=D[E])&&D.all){C=D.all[E]}for(A=0;!C&&A<D.forms.length;A++){C=D.forms[A][E]}for(A=0;!C&&D.layers&&A<D.layers.length;A++){C=MM_findObj(E,D.layers[A].document)}if(!C&&D.getElementById){C=D.getElementById(E)}return C}function MM_swapImage(){var C,B=0,D,A=MM_swapImage.arguments;document.MM_sr=new Array;for(C=0;C<(A.length-2);C+=3){if((D=MM_findObj(A[C]))!=null){document.MM_sr[B++]=D;if(!D.oSrc){D.oSrc=D.src}D.src=A[C+2]}}}function trackUrl(A,B){return"/tracker"+A+"%26t="+B}Minglebox.TextArea=function(A,C,B){this.ta=document.getElementById(A);this.gb=document.getElementById(C);this.gr=document.getElementById(B);this.h=250;this.w=250;this.dragx=false;this.dragy=false;this.oy=0;this.dy=0;this.ox=0;this.dx=0;this.nh=this.h;this.nw=this.w;Minglebox.addListener(this.gb,"mousedown",this._onDnY,this);Minglebox.addListener(this.gb,"mouseup",this._onUp,this);if(this.gr){Minglebox.addListener(this.gr,"mousedown",this._onDnX,this);Minglebox.addListener(this.gr,"mouseup",this._onUp,this)}Minglebox.addListener(document,"mouseup",this._onUp,this);Minglebox.addListener(document,"mousemove",this._onMv,this)};Minglebox.TextArea.prototype={resize:function(A){if(A.dragy&&A.dy!=0){A.nh+=A.dy;A.oy+=A.dy;A.ta.style.height=(A.nh-8)+"px"}if(A.dragx&&A.dx!=0){A.nw+=A.dx;A.ox+=A.dx;A.ta.style.width=(A.nw-8)+"px"}},_onDnY:function(B,A){if(B==null){B=window.event}A.dragy=true;A.oy=parseInt(B.clientY)},_onDnX:function(B,A){if(B==null){B=window.event}A.dragx=true;A.ox=parseInt(B.clientX)},_onMv:function(B,A){if(!A.dragx&&!A.dragy){return }if(B==null){B=window.event}if(A.dragy){A.dy=parseInt(B.clientY)-A.oy}else{if(A.dragx){A.dx=parseInt(B.clientX)-A.ox}}A.resize(A)},_onUp:function(B,A){A.h=A.nh;A.w=A.nw;if(B==null){B=window.event}A.dragx=false;A.dragy=false}};function setCookie(B,D,A,F,C,E){document.cookie=B+"="+escape(D)+((A)?"; expires="+A.toGMTString():"")+((F)?"; path="+F:"")+((C)?"; domain="+C:"")+((E)?"; secure":"")}function readCookie(B){var D=B+"=";var A=document.cookie.split(";");for(var C=0;C<A.length;C++){var E=A[C];while(E.charAt(0)==" "){E=E.substring(1,E.length)}if(E.indexOf(D)==0){return E.substring(D.length,E.length)}}return null}function eraseCookie(B,C){var A=new Date();A.setTime(A.getTime()+-1*60*60*1000);setCookie(B,"",A,((C)?C:""))}function wopen(D,C,A,F,E){A+=32;F+=96;var G=(screen.width-A)/2;var B=(screen.height-F)/2;var H=window.open(D,C,"width="+A+", height="+F+", left="+G+", top="+B+", location=no, menubar=no, status=yes, toolbar=no, scrollbars=no, resizable="+((E)?E:"yes"));if(!H){userWesiteId("Please enable popoups to chictchat in a separate window!");return true}else{H.focus()}return false}Minglebox.WinUp=function(A,D,C){this.url=A;this.mzi=D;this.urls=[addContextPath("/showtime.do"),addContextPath("/channel/campus.do"),addContextPath("/channel/people.do"),addContextPath("/channel/photos.do"),addContextPath("/channel/blogs.do"),addContextPath("/channel/groups.do"),addContextPath("/channel/video.do")];if(this.url){this.urls.push(this.url)}this.tID="";this.count=0;this.mIdle=C;var B=this;this.reloadPage();Minglebox.addListener(document,"mousemove",this.oreset,B);Minglebox.addListener(document,"keydown",this.oreset,B)};Minglebox.WinUp.prototype={oreset:function(B,A){clearTimeout(A.tID);A.count=0;A.reloadPage()},reloadPage:function(){var B=mb._get("chatWindow");if(B&&B.style.visibility=="visible"){this.count=0}else{this.count++;if(this.count==this.mIdle){window.location.replace(this.nextUrl(window.location.pathname))}}var A=this;this.tID=setTimeout(function(){A.reloadPage()},1000)},nextUrl:function(A){var B="";for(var C=0;C<this.urls.length;C++){if(A==this.urls[C]){B=(C+1)<this.urls.length?this.urls[C+1]:this.urls[0];break}}if(!B){B=this.urls[0]}B+=(B.indexOf("?")>0?"&":"?")+"mzi="+this.mzi;return B}};Minglebox.captureEnter=function(){this.c=null};Minglebox.captureEnter.prototype={capture:function(G,F,E,K,C,D,I,H){var B=window.event;if(!B){B=G}if(this.c!=17&&B.keyCode==13){Minglebox.Request.process(B,F,E,K,C,D,I);Minglebox.stopEvent(B)}else{if(this.c==17&&B.keyCode==13){var A=mb._get(H);if(A){var J=A.value;J=J+"\n";A.value=J;this.c=null;Minglebox.stopEvent(B)}else{Minglebox.Request.process(B,F,E,K,C,D,I)}}}this.c=B.keyCode}};var enterMgr=new Minglebox.captureEnter;var slideDownInitHeight=new Array();var slidedown_direction=new Array();var slidedownActive=false;var contentHeight=false;var slidedownSpeed=20;var slidedownTimer=7;function slidedown_showHide(D,C,B){if(!slidedown_direction[C]){slidedown_direction[C]=1}if(!slideDownInitHeight[C]){slideDownInitHeight[C]=0}if(slideDownInitHeight[C]==0){slidedown_direction[C]=slidedownSpeed}else{slidedown_direction[C]=slidedownSpeed*-1}var F=document.getElementById(C);var E=F.getElementsByTagName("DIV");var A=E?E[E.length-1]:F.height;contentHeight=A.offsetHeight;if(D){showComponent(D,C)}else{F.style.visibility="visible"}slidedownActive=true;slidedown_showHide_start(F,A)}function slidedown_showHide_start(B,A){if(!slidedownActive){return }slideDownInitHeight[B.id]=slideDownInitHeight[B.id]/1+slidedown_direction[B.id];if(slideDownInitHeight[B.id]<=0){slidedownActive=false;B.style.visibility="hidden";slideDownInitHeight[B.id]=0}if(slideDownInitHeight[B.id]>contentHeight){slidedownActive=false;slideDownInitHeight[B.id]=contentHeight}B.style.height=slideDownInitHeight[B.id]+"px";A.style.top=slideDownInitHeight[B.id]-contentHeight+"px";setTimeout('slidedown_showHide_start(document.getElementById("'+B.id+'"),document.getElementById("'+A.id+'"))',slidedownTimer)}function setSlideDownSpeed(A){slidedownSpeed=A}function setMoodCallback(C,B){addThemeCallback(C,B);var A=mb._get("moodSpan");if(A){A.innerHTML=C}slidedown_showHide(null,"box1","moodSpan")}function displayStandardMsg(A){var B=document.getElementById("ajaxMessages");var C=document.createElement("div");B.appendChild(C);if(C){C.className="promptDiv";C.innerHTML="<label color='green'>"+A+"</label>";C.style.visibility="visible"}}Minglebox.NavMgr=function(){this.ctrlMap=new Object();this.ctrlAltMap=new Object();this.ctrlMap[37]="ctrl-la";this.ctrlMap[39]="ctrl-ra";this.ctrlAltMap[72]="/user/home.do?method=view";this.ctrlAltMap[70]="/channel/friends.do?method=load";this.ctrlAltMap[67]="/channel/campus.do?method=load";this.ctrlAltMap[86]="/channel/video.do";this.ctrlAltMap[80]="/channel/photos.do";this.ctrlAltMap[71]="/channel/groups.do?method=load";this.ctrlAltMap[66]="/channel/blogs.do";this.ctrlAltMap[77]="/music/channel.do";this.ctrlAltMap[65]="/channel/people.do?method=load";Minglebox.addListener(document,"keydown",this.capture,this)};Minglebox.NavMgr.prototype={capture:function(D,B){var C=window.event?window.event:null;if(!C){C=D}var E=mb._get("kt_");if(E){E.value=E.value+(""+C.keyCode)}if(C.ctrlKey&&C.altKey){var A=B.ctrlAltMap[C.keyCode];if(A){B.url(A)}return }if(C.ctrlKey){var A=B.ctrlMap[C.keyCode];if(A){B.doAction(A)}}},doAction:function(A){var B=document.getElementsByName(A);if(B&&B.length>0){window.location.assign(B[0].href)}},url:function(A){window.location.assign(A)}};var navMgr__=new Minglebox.NavMgr;var sliderCount__=0;MediaSlider=function(C,B,A,E,D,G,F){sliderCount__++;this.pId=C+sliderCount__;this.opId=C;this.url=B;this.cb=A;this.thumbs=new Array();this.liId="imgBar"+this.pId;this.icId="ImageContainer"+this.pId;this.initialize=false;this.small=D?D:false;this.width=E?E:500;this.offset=G?G:0;this.pending=false;this.msg=F?F:"there is no matching content"};MediaSlider.prototype.fetch=function(A,C){if(this.pending){return }var B=this;if(!this.initialized){Minglebox.addListener(document.getElementById("moveLeft"+this.pId),"click",this.moveLeft,this);Minglebox.addListener(document.getElementById("moveRight"+this.pId),"click",this.moveRight,this);this.initialized=true}if(document.getElementById(B.liId)){document.getElementById(B.liId).style.display="block"}var D=C?this.offset:this.thumbs.length+this.offset;B.pending=true;Minglebox.Request.process(null,null,function(V,U){try{if(U.results&&U.results.length=="0"){if(document.getElementById(B.liId)){document.getElementById(B.liId).style.display="none"}if(B.thumbs.length=="0"){document.getElementById(B.icId).innerHTML="<td><b>"+B.msg+"</b></td>"}}else{for(var J=0;J<U.results.length;J++){var O=toMap(U.results[J]);B.thumbs[B.thumbs.length]=O.src.replace("m_data","s_data");if(document.getElementById(B.liId)){document.getElementById(B.liId).style.display="none"}if(B.thumbs[B.thumbs.length-1]==""){return }var N=document.createElement("TD");N.vAlign="bottom";var P=O.src;var H=O.link;var E=O.url;var S=O.caption;var M=O.id;var Q=document.createElement("IMG");Q.style.cursor="pointer";if(O.status==1){Q.style.border="3px solid green"}else{Q.style.border="1px solid black"}if(S){var T=S;if(O.status==1){T=T+" is online"}Q.title=T}Q.src=B.thumbs[B.thumbs.length-1];N.appendChild(Q);var L=document.createElement("DIV");L.style.clear="both";var F=document.createElement("P");F.align="center";var K=document.createTextNode(S.length>8?S.substr(0,8)+"..":S);F.appendChild(K);L.appendChild(F);N.appendChild(L);var I=C?B.offset+J:B.offset+B.thumbs.length;if(C&&document.getElementById(B.icId).firstChild){document.getElementById(B.icId).insertBefore(N,document.getElementById(B.icId).firstChild)}else{document.getElementById(B.icId).appendChild(N)}if(B.small){Q.width=53;Q.height=53}else{Q.width=65;Q.height=50}var G={self:B,thumb:P,page:H,embed:E,offset:I,mediaId:M};Minglebox.addListener(N,"click",B.cb,G);Minglebox.addListener(Q,"mousemove",B.growImg,B)}}}catch(R){}B.pending=false},null,addContextPath(this.url+"&limit="+A+"&offset="+D),null,null)};MediaSlider.prototype.getHtml=function(){var F=addContextPath("/images/Right.png");var C=addContextPath("/images/Right-On.png");var B=addContextPath("/images/Left.png");var D=addContextPath("/images/Left-On.png");var A=addContextPath("/images/preLoader.gif");var E='<table width="100%" id="mst'+this.pId+'"><tr><td valign="center" align="middle" width="6%"><img src="'+B+'"  id="moveRight'+this.pId+'" onmouseover="imgSwtchOn(this,\''+D+"')\" onmouseout=\"imgSwtchOn(this,'"+B+'\')" class="sliderLImg" alt="Left"></td><td><div id="interface'+this.pId+'" style="float:left;border:1px solid #e6e6e6;overflow:hidden;overflow-x:hidden;width:'+this.width+'px"><table border="0" cellpadding="2" cellspacing="1" height="110"><tr id="'+this.icId+'"></tr></table></div></td><td valign="center" align="middle" width="6%"><img src="'+F+'" id="moveLeft'+this.pId+'" onmouseover="imgSwtchOn(this,\''+C+"')\" onmouseout=\"imgSwtchOn(this,'"+F+'\')" class="sliderLImg" alt="Right"></td></tr><tr><td colspan="3" align="center" height="20"><img src="'+A+'" align="center" id="'+this.liId+'" style="display:none;" height="15" width="15"></td></tr></table>';return E};MediaSlider.prototype.moveLeft=function(A,C,E){var D=document.getElementById("interface"+C.pId);var B=D.scrollLeft;D.scrollLeft+=E?E:C.small?50:100;if(B==D.scrollLeft){C.fetch(10,false)}};MediaSlider.prototype.moveRight=function(B,D,F){var E=document.getElementById("interface"+D.pId);var C=E.scrollLeft;E.scrollLeft-=F?F:D.small?50:100;var A=0;if(C==E.scrollLeft&&D.offset>0){if(D.offset>10){D.offset-=9;A=10}else{A=D.offset-1;D.offset=0}D.fetch(10,true)}};MediaSlider.prototype.shrinkAll=function(A,B){};MediaSlider.prototype.growImg=function(A,C){var E;if(A.target){E=A.target}else{if(A.srcElement){E=A.srcElement}}if(E.nodeType==3){E=E.parentNode}var F=E.parentNode;C.resizeImg(F,C,C.small?100:130);var H=F.nextSibling;var B=C.small?83:115;while(H&&B>=(C.small?53:65)){C.resizeImg(H,C,B);B-=10;H=H.nextSibling}H=F.previousSibling;B=C.small?83:115;while(H&&B>=(C.small?53:65)){C.resizeImg(H,C,B);B-=10;H=H.previousSibling}var G=document.getElementById("interface"+C.pId);var D=F.offsetLeft-G.scrollLeft;if(D<100){C.moveRight(A,C,2)}else{if(D>200){C.moveLeft(A,C,2)}}};MediaSlider.prototype.resizeImg=function(G,C,B){if(G&&G.tagName=="TD"&&G.childNodes&&G.childNodes[0]){var F=G.childNodes[0];var A=C.small?53:65;var E=C.small?53:50;var D=E/A;F.width=B;F.height=B*D}};function makevisible(B,A){strength=(A==0)?1:0.2;if(B.style.MozOpacity){B.style.MozOpacity=strength}else{if(B.filters){B.filters.alpha.opacity=strength*100}}}function tabberObj(B){var A;this.div=null;this.classMain="tabber";this.classMainLive="tabberlive";this.classTab="tabbertab";this.classTabDefault="tabbertabdefault";this.classNav="tabbernav";this.classTabHide="tabbertabhide";this.classNavActive="tabberactive";this.titleElements=["h2","h3","h4","h5","h6"];this.titleElementsStripHTML=true;this.removeTitle=true;this.addLinkId=false;this.linkIdFormat="<tabberid>nav<tabnumberone>";for(A in B){this[A]=B[A]}this.REclassMain=new RegExp("\\b"+this.classMain+"\\b","gi");this.REclassMainLive=new RegExp("\\b"+this.classMainLive+"\\b","gi");this.REclassTab=new RegExp("\\b"+this.classTab+"\\b","gi");this.REclassTabDefault=new RegExp("\\b"+this.classTabDefault+"\\b","gi");this.REclassTabHide=new RegExp("\\b"+this.classTabHide+"\\b","gi");this.tabs=new Array();if(this.div){this.init(this.div);this.div=null}}tabberObj.prototype.init=function(E){var H,D,B,J,F=0,K,A,I,C,G;if(!document.getElementsByTagName){return false}if(E.id){this.id=E.id}this.tabs.length=0;H=E.childNodes;for(D=0;D<H.length;D++){if(H[D].className&&H[D].className.match(this.REclassTab)){J=new Object();J.div=H[D];this.tabs[this.tabs.length]=J;if(H[D].className.match(this.REclassTabDefault)){F=this.tabs.length-1}}}K=document.createElement("ul");K.className=this.classNav;for(D=0;D<this.tabs.length;D++){J=this.tabs[D];J.headingText=J.div.title;if(this.removeTitle){J.div.title=""}if(!J.headingText){for(B=0;B<this.titleElements.length;B++){G=J.div.getElementsByTagName(this.titleElements[B])[0];if(G){J.headingText=G.innerHTML;if(this.titleElementsStripHTML){J.headingText.replace(/<br>/gi," ");J.headingText=J.headingText.replace(/<[^>]+>/g,"")}break}}}if(!J.headingText){J.headingText=D+1}A=document.createElement("li");J.li=A;I=document.createElement("a");I.innerHTML="<strong>"+J.headingText+"</strong>";I.href="javascript:void(null);";I.title=J.headingText;I.onclick=this.navClick;I.tabber=this;I.tabberIndex=D;if(this.addLinkId&&this.linkIdFormat){C=this.linkIdFormat;C=C.replace(/<tabberid>/gi,this.id);C=C.replace(/<tabnumberzero>/gi,D);C=C.replace(/<tabnumberone>/gi,D+1);C=C.replace(/<tabtitle>/gi,J.headingText.replace(/[^a-zA-Z0-9\-]/gi,""));I.id=C}A.appendChild(I);K.appendChild(A)}E.insertBefore(K,E.firstChild);E.className=E.className.replace(this.REclassMain,this.classMainLive);this.tabShow(F);if(typeof this.onLoad=="function"){this.onLoad({tabber:this})}return this};tabberObj.prototype.navClick=function(F){var C,A,B,E,D;A=this;if(!A.tabber){return false}B=A.tabber;E=A.tabberIndex;if(B.cb[E]&&typeof B.cb[E]=="function"){B.cb[E]()}A.blur();if(typeof B.onClick=="function"){D={tabber:B,index:E,event:F};if(!F){D.event=window.event}C=B.onClick(D);if(C===false){return false}}B.tabShow(E);return false};tabberObj.prototype.tabHideAll=function(){var A;for(A=0;A<this.tabs.length;A++){this.tabHide(A)}};tabberObj.prototype.tabHide=function(A){var B;if(!this.tabs[A]){return false}B=this.tabs[A].div;if(!B.className.match(this.REclassTabHide)){B.className+=" "+this.classTabHide}this.navClearActive(A);return this};tabberObj.prototype.tabShow=function(A){var B;if(!this.tabs[A]){return false}this.tabHideAll();B=this.tabs[A].div;B.className=B.className.replace(this.REclassTabHide,"");this.navSetActive(A);if(typeof this.onTabDisplay=="function"){this.onTabDisplay({tabber:this,index:A})}return this};tabberObj.prototype.navSetActive=function(A){this.tabs[A].li.className=this.classNavActive;return this};tabberObj.prototype.navClearActive=function(A){this.tabs[A].li.className="";return this};function initTabs(B){if(!B){B="tabberdiv"}var A,D,C;var E={};A=new tabberObj(E);D=document.getElementById(B).getElementsByTagName("div");for(C=0;C<D.length;C++){if(D[C].className&&D[C].className.match(A.REclassMain)){E.div=D[C];ttabs=D[C].getElementsByTagName("div");E.cb={};tt=0;for(t=0;t<ttabs.length;t++){if(ttabs[t].className&&ttabs[t].className.match(A.REclassTab)){if(ttabs[t].onclick){E.cb[tt]=ttabs[t].onclick}tt++}}D[C].tabber=new tabberObj(E)}}}function imgSwtchOn(A,B){A.src=B}function updateTags(B,D,C){var E=mb._get(B);var A=E.value;if(C){if(A.search(D)==-1){E.value=E.value+" "+D}}else{if(A.search(D)!=-1){E.value=A.replace(D,"")}}}var enabletip=false;function ddrivetip(C,E,B){var A=document.getElementById("tagtooltip");if(A){try{if(typeof B!="undefined"){A.style.width=B+"px"}if(typeof E!="undefined"&&E!=""){A.style.backgroundColor=E}A.innerHTML=C;enabletip=true}catch(D){}}return false}function positiontip(A){if(enabletip){return showComponent(A,"tagtooltip")}return false}function hideddrivetip(){var A=document.getElementById("tagtooltip");if(A){try{enabletip=false;A.style.visibility="hidden";A.style.left="-1000px";A.style.backgroundColor="";A.style.width=""}catch(B){}}}Minglebox.addListener(document,"mousemove",positiontip,null);var fuo__=new Array();AjaxFileUpload=function(D,C,G,A,E){var F=fuo__.length;fuo__.push(this);this.fileForm=D;var B=document.createElement("input");B.type="hidden";B.name="ajaxUploadObjectId";B.value=F;D.appendChild(B);this.fuCallback=C;this.progressDiv=document.getElementById(G?G:"progressBar");this.progressText=document.getElementById(A?A:"progressBarText");this.progressContent=document.getElementById(E?E:"progressBarBoxContent");if(!this.progressDiv){this.progressDiv=document.getElementById("progressBar");this.progressText=document.getElementById("progressBarText");this.progressContent=document.getElementById("progressBarBoxContent")}this.req=null;this.oSelf=this;theAjaxUploadObject=this};AjaxFileUpload.prototype.id=null;AjaxFileUpload.prototype.fileForm=null;AjaxFileUpload.prototype.fuCallback=null;AjaxFileUpload.prototype.progressDiv=null;AjaxFileUpload.prototype.req=null;AjaxFileUpload.prototype.oSelf=null;AjaxFileUpload.prototype.processed=false;AjaxFileUpload.prototype={start:function(){},processResponse:function(){}};AjaxFileUpload.prototype.start=function(){this.processed=false;if(this.fuCallback!=null){this.fuCallback("start")}this.fileForm.submit();this.progressDiv.style.display="block";this.progressContent.style.width="0%";this.progressText.innerHTML="0%";var A=this;setTimeout(function(){A.checkProgress()},50)};AjaxFileUpload.prototype.checkProgress=function(){var A=this;Minglebox.Request.process(null,null,function(C,B){A.statusCallback(C,B)},null,addContextPath("/status.jsp?dummy="+new Date().getTime()),null,null)};AjaxFileUpload.prototype.statusCallback=function(B,A){var C=A&&A.results&&A.results[0]&&A.results[0][0]?A.results[0][0].value:0;this.progressText.innerHTML=C+"%";this.progressContent.style.width=C+"%";if(C<100){a=this;setTimeout(function(){a.checkProgress()},50)}else{if(this.progressDiv){this.progressDiv.style.display="none"}if(!this.processed){this.fuCallback("complete",null)}}if(document.getElementById("pUpPb")){var D=document.getElementById("pUpPb");D.style.display="block"}};AjaxFileUpload.prototype.processResponse=function(E){var A=null;if(window.ActiveXObject){A=new ActiveXObject("Microsoft.XMLDOM");A.async=false;A.loadXML(E)}else{if(window.XMLHttpRequest){var F=new DOMParser();A=F.parseFromString(E,"text/xml")}}var B={};try{B.status="success";Minglebox.Request.processXml(A,B)}catch(D){}this.processed=true;this.fuCallback("end",B);if(document.getElementById("pUpPb")){var C=document.getElementById("pUpPb");C.style.display="none"}};function handleResponse(A,B){fuo__[A].processResponse(B)}function strtrim(A){A=this!=window?this:A;return A.replace(/^\s+/g,"").replace(/\s+$/g,"")}function constructRedirectUrl(A){return window.location.protocol+"//"+window.location.host+strtrim(unescape(A))}function LTrim(B){var A=/\s*((\S+\s*)*)/;return B.replace(A,"$1")}function RTrim(B){var A=/((\s*\S+)*)\s*/;return B.replace(A,"$1")}function trim(A){return LTrim(RTrim(A))}var mbNavtabs={subcontainers:[],last_accessed_tab:null,selected_tab:null,showMenu:function(A,B){if(A.last_accessed_tab!=null){A.last_accessed_tab.className=""}if(B!=null){B.className="current"}A.last_accessed_tab=B;A.revealsubmenu(A,B)},revealsubmenu:function(A,B){A.hideallsubs(A);if(B!=null&&B.getAttribute("id")&&document.getElementById(B.getAttribute("id")+"Sub")){document.getElementById(B.getAttribute("id")+"Sub").style.display="block"}},hideallsubs:function(B){for(var A=0;A<B.subcontainers.length;A++){if(document.getElementById(B.subcontainers[A])){document.getElementById(B.subcontainers[A]).style.display="none"}}},init:function(B,G,A){var D=this;var F;var E=document.getElementById(G).getElementsByTagName("a");for(var C=0;C<E.length;C++){if(E[C].getAttribute("id")){this.subcontainers[this.subcontainers.length]=E[C].getAttribute("id")+"Sub"}if(A!=""){if(C==A||E[C].getAttribute("id").indexOf(A)==0){this.selected_tab=E[C];E[C].className="current";this.showMenu(this,E[C])}}E[C].onmouseover=function(H){D.showMenu(D,this)}}document.getElementById(B).onmouseover=function(H){clearTimeout(D.tId)};document.getElementById(B).onmouseout=function(H){if(checkMouseLeave(this,H)){D.tId=setTimeout(function(){D.showMenu(D,D.selected_tab)},3000)}}}};function showMoreMenu(A){document.getElementById(A.id+"Vert").style.display="block"}function hideMoreMenu(A,B){document.getElementById(A.id).style.display="none"}function containsDOM(A,C){var B=false;do{if((B=A==C)){break}C=C.parentNode}while(C!=null);return B}function checkMouseLeave(B,A){if(document.all){A=window.event}if(B.contains&&A.toElement){return !B.contains(A.toElement)}else{if(A.relatedTarget){return !containsDOM(B,A.relatedTarget)}}}var RUZEE=window.RUZEE||{};RUZEE.ShadedBorder={create:function(U){var f=/msie/i.test(navigator.userAgent)&&!window.opera;function T(m,b){for(k in b){if(/ie_/.test(k)){if(f){m.style[k.substr(3)]=b[k]}}else{m.style[k]=b[k]}}}function Z(m){var b=document.createElement("div");b.className="sb-gen";T(b,m);return b}function P(b){b=b<0?0:b;b=b>0.99999?0.99999:b;return f?" filter:alpha(opacity="+(b*100)+");":" opacity:"+b+";"}var d=U.shadow||0;var X=U.corner||0;var W=0;var Q=U.border||0;var L=d!=0;var H=X>d?X:d;var J=H;var K=H;var E=H;if(Q>0){W=X;X=X-Q}var F=X!=0&&L?Math.round(H/3):0;var D=F;var I=Math.round(F/2);var N=X>0?"sb-inner":"sb-shadow";var c="sb-shadow";var R="sb-border";var C=U.edges||"trlb";if(!/t/i.test(C)){K=0}if(!/b/i.test(C)){E=0}if(!/l/i.test(C)){H=0}if(!/r/i.test(C)){J=0}var Y={position:"absolute",left:"0",top:"0",width:H+"px",height:K+"px",ie_fontSize:"1px",overflow:"hidden",margin:"0",padding:"0"};var G=Z(Y);delete Y.left;Y.right="0";Y.width=J+"px";var B=Z(Y);delete Y.top;Y.bottom="0";Y.height=E+"px";var j=Z(Y);delete Y.right;Y.left="0";Y.width=H+"px";var A=Z(Y);var l=Z({position:"absolute",width:"100%",height:K+"px",ie_fontSize:"1px",top:"0",left:"0",overflow:"hidden",margin:"0",padding:"0"});var S=Z({position:"relative",height:K+"px",ie_fontSize:"1px",margin:"0 "+J+"px 0 "+H+"px",overflow:"hidden",padding:"0"});l.appendChild(S);var e=Z({position:"absolute",left:"0",bottom:"0",width:"100%",height:E+"px",ie_fontSize:"1px",overflow:"hidden",margin:"0",padding:"0"});var h=Z({position:"relative",height:E+"px",ie_fontSize:"1px",margin:"0 "+J+"px 0 "+H+"px",overflow:"hidden",padding:"0"});e.appendChild(h);var V=Z({position:"absolute",top:(-E)+"px",left:"0",width:"100%",height:"100%",overflow:"hidden",ie_fontSize:"1px",padding:"0",margin:"0"});function M(o,AC,AG){var z=AG?H:J;var AJ=AC?K:E;var AD=AC?I:-I;var r=[];var p=[];var b=[];var AA=0;var AH=1;if(AG){AA=z-1;AH=-1}for(var v=0;v<z;++v){var AK=AJ-1;var m=-1;if(AC){AK=0;m=1}var q=false;for(var u=AJ-1;u>=0&&!q;--u){var AE='<div style="position:absolute; top:'+AK+"px; left:"+AA+"px; width:1px; height:1px; overflow:hidden; margin:0; padding:0;";var AI=v-F;var n=u-D-AD;var AL=Math.sqrt(AI*AI+n*n);var AB=false;if(X>0){if(AI<0&&n<W&&n>=X||n<0&&AI<W&&AI>=X){r.push(AE+'" class="'+R+'"></div>')}else{if(AL<W&&AL>=X-1&&AI>=0&&n>=0){var AM=AE;if(AL>=W-1){AM+=P(W-AL);AB=true}r.push(AM+'" class="'+R+'"></div>')}}var AM=AE+" z-index:2;"+(AC?"background-position:0 -"+(X-n-1)+"px;":"background-image:none;");var AF=function(){if(!AC){AM=AM.replace(/top\:\d+px/,"top:0px")}AM=AM.replace(/height\:1px/,"height:"+(u+1)+"px");p.push(AM+'" class="'+N+'"></div>');q=true};if(AI<0&&n<X||n<0&&AI<X){AF()}else{if(AL<X&&AI>=0&&n>=0){if(AL>=X-1){AM+=P(X-AL);AB=true;p.push(AM+'" class="'+N+'"></div>')}else{AF()}}else{AB=true}}}else{AB=true}if(d>0&&AB){AL=Math.sqrt(v*v+u*u);if(AL<d){b.push(AE+" z-index:0; "+P(1-(AL/d))+'" class="'+c+'"></div>')}}AK+=m}AA+=AH}o.innerHTML=b.concat(r.concat(p)).join("")}function g(p){var o=[];o.push('<div style="position:relative; top:'+(K+E)+"px; height:2048px;  margin:0 "+(J-X-F)+"px 0 "+(H-X-F)+"px;  padding:0; overflow:hidden; background-position:0 "+(K>0?-(X+D+I):"0")+'px;" class="'+N+'"></div>');var m='<div style="position:absolute; width:1px; top:'+(K+E)+"px; height:2048px; padding:0; margin:0;";for(var b=0;b<H-X-F;++b){o.push(m+" left:"+b+"px;"+P((b+1)/H)+'" class="'+c+'"></div>')}for(var b=0;b<J-X-F;++b){o.push(m+" right:"+b+"px;"+P((b+1)/J)+'" class="'+c+'"></div>')}if(Q>0){var n=" width:"+Q+'px;" class="'+R+'"></div>';o.push(m+" left:"+(H-W-F)+"px;"+n);o.push(m+" right:"+(J-W-F)+"px;"+n)}p.innerHTML=o.join("")}function O(p,m){var q=[];var o=m?K:E;var b='<div style="height:1px; overflow:hidden; position:absolute; margin:0; padding:0; width:100%; left:0px; ';var n=m?I:-I;for(var r=0;r<o-n-D-X;++r){q.push(b+(m?"top:":"bottom:")+r+"px;"+P((r+1)*1/o)+'" class="'+c+'"></div>')}if(r>=Q){q.push(b+(m?"top:":"bottom:")+(r-Q)+"px; height:"+Q+'px;" class="'+R+'"></div>')}q.push(b+(m?"background-position-y:0; top:":"background-image:none; bottom:")+r+"px; height:"+(X+D+n)+'px;" class="'+N+'"></div>');p.innerHTML=q.join("")}M(G,true,true);M(B,true,false);M(A,false,true);M(j,false,false);g(V);O(S,true);O(h,false);return{render:function(m){if(typeof m=="string"){m=document.getElementById(m)}if(m.length!=undefined){for(var p=0;p<m.length;++p){this.render(m[p])}return }m.className+=" sb";T(m,{position:"relative",background:"transparent"});var n=m.firstChild;while(n){var o=n.nextSibling;if(n.nodeType==1&&n.className=="sb-gen"){m.removeChild(n)}n=o}var v=m.firstChild;var q=l.cloneNode(true);var u=V.cloneNode(true);var r=e.cloneNode(true);m.insertBefore(G.cloneNode(true),v);m.insertBefore(B.cloneNode(true),v);m.insertBefore(A.cloneNode(true),v);m.insertBefore(j.cloneNode(true),v);m.insertBefore(q,v);m.insertBefore(u,v);m.insertBefore(r,v);if(f){function b(){q.style.width=r.style.width=u.style.width=m.offsetWidth+"px";u.firstChild.style.height=m.offsetHeight+"px"}m.onresize=b;b()}}}}};function initShadow(){var B=new Array("lb1","lb2","rb1","rb2","rb3","rb4");var A=RUZEE.ShadedBorder.create({corner:10,shadow:20});for(i=0;i<B.length;i++){if(document.getElementById(B[i])){A.render(B[i])}}}Minglebox.CMgr=function(C,E,D,B,A){this.handler=new Object();this.tO=C;this.id=E;this.n=D;this.d=B;this.m=A;this.init()};Minglebox.CMgr.uri="/cricket.do";Minglebox.CMgr.prototype={init:function(){switch(this.n){case 0:this.startTicker(this.id);break;case 1:this.startMinicard(this.id);break;case 2:this.startFullcard(this.id);break;default:break}},ticker:function(){this.send(Minglebox.CMgr.uri+"?method=ticker&matchId="+this.id)},minicard:function(){this.send(Minglebox.CMgr.uri+"?method=minicard&matchId="+this.id)},fullcard:function(){var A=mb._get(this.m);if(A){A.innerHTML=": refreshing"}this.send(Minglebox.CMgr.uri+"?method=fullcard&matchId="+this.id)},send:function(A){var B=this;Minglebox.Request.process(null,null,function(D,C){B.callback(D,C)},null,addContextPath(A),null,null)},callback:function(C,D){var B=mb._get(this.m);if(B){B.innerHTML=""}B=mb._get(this.d);if(B){B.innerHTML=D.text;var A=this;setTimeout(function(){A.request()},A.tO)}},getHandler:function(){return this.handler.handler},request:function(){this.getHandler().call(this)},register:function(A){this.handler.handler=A},startTicker:function(A){this.id=A;this.register(this.ticker);this.ticker()},startMinicard:function(A){this.id=A;this.register(this.minicard);this.minicard()},startFullcard:function(A){this.id=A;this.register(this.fullcard);this.fullcard()}};function MM_showHideLayers(){var C,E,A,D,B=MM_showHideLayers.arguments;for(C=0;C<(B.length-2);C+=3){if((D=MM_findObj(B[C]))!=null){A=B[C+2];if(D.style){D=D.style;A=(A=="show")?"visible":(A=="hide")?"hidden":A}D.visibility=A}}}function showBg(C,B){var F=document.getElementById(C);var E=F.style.display;var D=document.getElementById(B);var A=D.style.display;F.style.display="none";D.style.display="block"}function importAuth(A){alert("Now you will be redirected to the Google Authentication Page...");window.open("/blog/post.do?method=importBlogs&websiteId="+A,"_top")}function importSelf(A){window.open("/blog/post.do?method=importBlogs&websiteId="+A,"_top")}function toggleClassCri(C,D,A,B){C.parentNode.className=D;document.getElementById(A).style.display="block";document.getElementById(B).style.display="none"}function showMoreCri(C,A,D,B){C.style.display="none";document.getElementById(A).style.display="block";if(B==true){document.getElementById(D).style.display="block"}else{document.getElementById(D).style.display="none"}}function validateRfi(){var H="Name *";var B="E-mail Address *";var I="Contact Number *";var F="your query here...";var G=document.getElementById("rfiFormEx");var A=G.name.value;var D=G.email.value;var C=G.contactNumber.value;var E=G.query.value;if(A==H){alert("Please provide your name");G.name.focus();return false}if(D==B){alert("Please provide your email");G.email.focus();return false}if(!(checkemail(G,D))){return false}if(C==I){alert("Please provide your contact number");G.contactNumber.focus();return false}if((C==null)||(C=="")){alert("Please provide your contact number");G.contactNumber.focus();return false}if(checkInternationalPhone(C)==false){alert("Please provide a valid phone number");G.contactNumber.value="";G.contactNumber.focus();return false}if(E==F){alert("Please provide us with relevant details of your query");G.query.focus();return false}document.getElementById("btnsbmt").style.display="none";document.getElementById("btnprcs").style.display="block";return true}function validateQnARfi(){var I="Name *";var C="E-mail Address *";var J="Contact Number *";var G="Type your Question here...";var H=document.getElementById("rfiFormEx");var A=H.name.value;var E=H.email.value;var D=H.contactNumber.value;var F=H.query.value;var B=H.preferredLocation;if(A==I){alert("Please provide your name");H.name.focus();return false}if(E==C){alert("Please provide your email");H.email.focus();return false}if(!(checkemail(H,E))){return false}if(D==J){alert("Please provide your contact number");H.contactNumber.focus();return false}if((D==null)||(D=="")){alert("Please provide your contact number");H.contactNumber.focus();return false}if(checkInternationalPhone(D)==false){alert("Please provide a valid phone number");H.contactNumber.value="";H.contactNumber.focus();return false}if(B!=null){if(B.value=="none"){alert("Please provide your Study Preference");H.preferredLocation.focus();return false}}if(F==G){alert("Please provide us with relevant details of your query");H.query.focus();return false}document.getElementById("btnsbmt").style.display="none";document.getElementById("btnprcs").style.display="inline";return true}function validateManipal(){var H="Full Name *";var F="E-mail *";var G="Mobile Number *";var E=document.getElementById("mbUserFormEx");var D=E.name.value;var C=E.emailAddress.value;var B=E.mobileNumber.value;var A=E.value3.value;if(D==H){alert("Please provide your name");E.name.focus();return false}if(C==F){alert("Please provide your email");E.emailAddress.focus();return false}if(!(checkemail1(E,C))){return false}if(B==G){alert("Please provide your contact number");E.mobileNumber.focus();return false}if((B==null)||(B=="")){alert("Please provide your contact number");E.mobileNumber.focus();return false}if(checkInternationalPhone(B)==false){alert("Please provide a valid phone number");E.mobileNumber.value="";E.mobileNumber.focus();return false}if((A==null)||(A=="")){alert("Please provide your choice of stream");E.value3.focus();return false}E.redirectUrl.value=E.redirectUrl.value+"&value3="+A;return true}function clearData(){var B="your query here...";document.getElementById("btnsbmt").style.display="block";document.getElementById("btnprcs").style.display="none";var A=document.getElementById("rfiFormEx");A.name.value=A.nmVal.value;A.email.value=A.emailVal.value;A.contactNumber.value=A.mobVal.value;A.query.value=B}function clearMsRfiFormData(){document.getElementById("btnsbmt").style.display="block";document.getElementById("btnprcs").style.display="none";var A=document.getElementById("rfiFormEx1");A.name.value="";A.email.value="";A.contactNumber.value="";A.city.value="";var B=A.query;if(B!=null){B.value=""}}function clearQnAData(){var B="Type your Question here...";document.getElementById("btnsbmt").style.display="inline";document.getElementById("btnprcs").style.display="none";var A=document.getElementById("rfiFormEx");A.name.value=A.nmVal.value;A.email.value=A.emailVal.value;A.contactNumber.value=A.mobVal.value;A.query.value=B}function fillLocations(F,D){var E=document.getElementById(F);E.options.length=0;E.options[0]=new Option("No Preference","",false,false);var B=locationList();for(var C=1;C<=B.length;C++){E.options[C]=new Option(B[C-1],B[C-1],false,false)}var A=getLocIndex(D);if(A>=0){E.selectedIndex=A+1}}function fillQnALocations(F,D){var E=document.getElementById(F);E.options.length=0;E.options[0]=new Option("Study Preference*","none",false,false);E.options[1]=new Option("No Preference","",false,false);var B=locationList();for(var C=0;C<B.length;C++){E.options[C+2]=new Option(B[C],B[C],false,false)}var A=getLocIndex(D);if(A>=0){E.selectedIndex=A+1}}function fillCityLocations(F,D){var E=document.getElementById(F);E.options.length=0;E.options[0]=new Option("Select ...","",false,false);var B=locationList();for(var C=1;C<=B.length;C++){E.options[C]=new Option(B[C-1],B[C-1],false,false)}var A=getLocIndex(D);if(A>=0){E.selectedIndex=A+1}}function fillAllLocations(G,D){var E=document.getElementById(G);E.options.length=0;var F=0;E.options[F++]=new Option("Select ...","",false,false);E.options[F++]=new Option("No Preference","nopref",false,false);E.options[F++]=new Option("North India","North",false,false);E.options[F++]=new Option("South India","South",false,false);E.options[F++]=new Option("East India","East",false,false);E.options[F++]=new Option("West India","West",false,false);E.options[F++]=new Option("Study in USA","studyusa",false,false);E.options[F++]=new Option("Study in UK","studyuk",false,false);E.options[F++]=new Option("Study in Australia","studyaustralia",false,false);E.options[F++]=new Option("Study in Singapore","studysingapore",false,false);var B=locationList();for(var C=1;C<=B.length;C++){E.options[F++]=new Option(B[C-1],B[C-1],false,false)}var A=getLocIndex(D);if(A>=0){E.selectedIndex=A+10}else{if(D=="nopref"){E.selectedIndex=A+2}else{if(D=="North"){E.selectedIndex=A+3}else{if(D=="South"){E.selectedIndex=A+4}else{if(D=="East"){E.selectedIndex=A+5}else{if(D=="West"){E.selectedIndex=A+6}else{if(D=="studyusa"){E.selectedIndex=A+7}else{if(D=="studyuk"){E.selectedIndex=A+8}else{if(D=="studyaustralia"){E.selectedIndex=A+9}else{if(D=="studysingapore"){E.selectedIndex=A+10}}}}}}}}}}}function setSelected(A,C){var B=document.getElementById(C);if(A>=0){B.selectedIndex=A+1}}function setSelectedTerm(B,C){var A=getLocIndex(B);setSelected(A,C)}function locationList(){return Array("Bangalore","Chennai","Delhi","Hyderabad","Kolkata","Mumbai","Pune","Agra","Agraharam","Ahmedabad","Ahmednagar","Aizawl","Ajmer","Aligarh","Allahabad","Alwar","Ambala","Amravati","Anantapur","AndhraPradesh","Aurangabad","Badnera","Bagalkot","Balasore","Banda","Barabanki","Baramati","Bareilly","Belgaum","Bellary","Bengaluru/bangalore","Bhalki","Bhavnagar","Bhimavaram","Bhopal","Bhubaneshwar","Bhubaneswar","Bihar","Bijapur","Bijnor","Bikaner","Bilaspur","Bokaro","Buldana","Calcutta","Calicut","Chandigarh","Chandrapur","Chengalpattu","Chengannur","Chitrakoot","Chittoor","Chopda","Cochin","Coimbatore","Cuddapah","Cuttack","Darbhanga","Darjeeling","Dehradun","Dhanbad","Dharmapuri","Dharwad","Dhule","Dindigul","Durgapur","Eluru","Erode","Faridabad","Gandhinagar","Ganjam","Gargaon","GautamBudhNagar","Gaya","Ghaziabad","Goa","Goa-Other","Gondia","GreaterNoida","Guhawati","Gujarat-Other","Guntur","Gurgaon","Guwahati","Guwhati","Gwalior","Haridwar","Harihar","Haryana-Other","Hassan","HimachalPradesh-Other","Himayatnagar","Hindupur","Hisar","Hyderabad/Secunderabad","Ichalkaranji","Imphal","Inchal","IndiaDelhi","IndiaNagpur","Indore","Jabalpur","Jagadhri","Jaipur","Jalandhar","Jalgaon","Jammu","Jammu&Kashmir-Other","Jamshedpur","Jaunpur","Jhansi","Jodhpur","Kakinada","Kalavakkam","Kanchipuram","Kanpur","Karad","Karaikudi","Karimnagar","Karnal","Karnataka","Kerala-Other","Khammam","Khandala","Kharagpur","Kilakarai","Kochi","Kodaikanal","Kolar","Kolhapur","Kota","Kottayam","Krishna","Kurukshetra","Lakshmangarh","Latur","Loni","Lucknow","Ludhiana","Madras","Madurai","Maharashtra","Mahboobnagar","Mangalore","Manipal","Mathura","Meerut","Meghalaya-Other","Mehsana","Miraj","Mizoram-Other","Modinagar","Moga","Mohali","Moradabad","MumbaiSuburbs","Muzaffarnagar","Muzaffarpur","Mysore","Nadiad","Nagaland-Other","Nagpur","Namakkal","Nanded","Nandyal","Nashik","Nasik","NaviMumbai","Nellore","Nizamabad","Noida","Ooty","Orissa-Other","Palakkad","Panchkula","Patan","Patiala","Patna","Periyar","Perundurai","Pollachi","Pondicherry","Punjab","Puri","Raipur","Rajahmundry","Rajasthan","Ramtek","Ranchi","Rayagada","Rayavaram","Rewa","Ribandar","Rohtak","Roorkee","Rourkela","Sagar","Sahib","Salem","Samastipur","Sambalpur","Sangli","Satara","Secunderabad","Shegaon","Shimla","Shimoga","Shrirampur","Sikar","Sikkim-Other","Sindhudurg","Sirsa","Sivakasi","Solapur","Sonepat","Srikakulam","Srinagar","Tambaram","TamilNadu","Tezpur","Thane","Thanjavur","Thiruvallur","Thiruvalluvar","Thiruvananthapuram","Tiruchengode","Tiruchirapalli","Tiruchirappalli","Tiruninravur","Tirupati","Trichy","Trivandrum","Tumkur","Udaipur","Ujire","Ujjain","UttarPradesh-Other","Uttaranchal-Other","Vadodara","VallabhVidyanagar","Vapi","Varanasi","Vellore","Vijayawada","Virudhunagar","Visakhapatnam","Warangal","Wardha","WestBengal-Other","YamunaNagar","Yamunanagar","Yavatmal")}function getLocIndex(A){if(A!=null&&A!=""){var B=locationList();return B.indexOf(A)}return -1}function checkemail1(D,B){var A;var E=B;var C=/^.+@.+\..{2,3}$/;if(C.test(E)){A=true}else{alert("Please input a valid email address!");D.emailAddress.value="";D.emailAddress.focus();A=false}return(A)}function checkemail(D,B){var A;var E=B;var C=/^.+@.+\..{2,3}$/;if(C.test(E)){A=true}else{alert("Please input a valid email address!");D.email.value="";D.email.focus();A=false}return(A)}function isFloat(C){var B;var A=false;for(B=0;B<C.length;B++){var D=C.charAt(B);if(((D<"0")||(D>"9")||((D!=".")&&(!A)))){return false}if(D=="."){A=true}}return true}function isInteger(B){var A;for(A=0;A<B.length;A++){var C=B.charAt(A);if(((C<"0")||(C>"9"))){return false}}return true}function trim2(C){var B;var A="";for(B=0;B<C.length;B++){var D=C.charAt(B);if(D!=" "){A+=D}}return A}function stripCharsInBag(C,D){var B;var A="";for(B=0;B<C.length;B++){var E=C.charAt(B);if(D.indexOf(E)==-1){A+=E}}return A}function checkInternationalPhone(B){var A="()- ";var D=A+"+";var H=10;var G=3;B=trim(B);if(B.indexOf("+")>1){return false}if(B.indexOf("-")!=-1){G=G+1}if(B.indexOf("(")!=-1&&B.indexOf("(")>G){return false}var F=B.indexOf("(");if(B.indexOf("(")!=-1&&B.charAt(F+2)!=")"){return false}if(B.indexOf("(")==-1&&B.indexOf(")")!=-1){return false}s=stripCharsInBag(B,D);if(s.length>H){var E=s.length-H;var C=0;for(C=0;C<E;C++){if(s.substring(C,C+1)!="0"){break}}if(C>0){s=s.substring(C)}}if(s.length==12&&s.substring(0,2)=="91"){s=s.substring(2)}return(isInteger(s)&&s.length==H&&(s.substring(0,1)=="9"||s.substring(0,1)=="8"))}function rfiCallback(A,B){if(B.status=="success"){alert("Thank you for your query. We will get back to you as soon as possible")}clearData()}function msRfiCallback(A,B){if(B.status=="success"){alert("Thank you for your query. We will get back to you as soon as possible")}clearMsRfiFormData()}function rfiQnACallback(A,B){if(B.status=="success"){alert("Thank you for your query. We will get back to you as soon as possible")}clearQnAData()}function signupCallback(A,B){if(B.status=="success"){document.getElementById("PopUp").style.display="block"}}function shareloader(){document.getElementById("loader").style.visibility="visible"}Minglebox.popup=function(A){var B=mb._get(A);var G,E;if(self.pageYoffset){G=self.pageXoffset;E=self.pageYoffset}else{if(document.documentElement&&document.documentElement.scrollTop){G=document.documentElement.scrollLeft;E=document.documentElement.scrollTop}else{if(document.body){G=document.body.scrollLeft;E=document.body.scrollTop}}}var F,D;if(self.innerHeight){F=self.innerWidth;D=self.innerHeight}else{if(document.documentElement&&document.documentElement.clientheight){F=document.documentElement.clientWidth;D=document.documentElement.clientheight}else{if(document.body){F=document.body.clientWidth;D=document.body.clientHeight}}}if(document.body){var H=((F/2)-(B.offsetWidth/2))/2}else{var H=G+(F-B.offsetWidth)/2}if(document.body){var C=E+(isIE6()?100:300)}else{var C=E+(D-B.offsetHeight)/2}B.style.top=C+"px";B.style.left=H+"px";B.style.display="block"};Minglebox.share=function(F,H,J,B,D,L,G,K,C,E){__go_share__=new ShareObject(H,J,B,D,L,G,K,C,E);var I=mb._get("share_container");var A=mb._get("shareContent");if(!I){Minglebox.popup("shareContent")}else{I.style.display="block";A.style.display="block"}A.innerHTML='<iframe name="shareframe" id="shareframe" src="/share/sharewindow.jsp" marginwidth="0" marginheight="0" vspace="0" hspace="0" allowtransparency="true" frameborder="0" scrolling="no" width="500" height="550"></iframe>';return false};ShareObject=function(F,G,A,C,I,E,H,B,D){this.login=F;this.title=G;this.url=A;this.imgurl=C;this.message=I;this.subject=E;this.content=D;this.contentType=H;this.beforeContent=B};function initTransliterationApi(D,B,F){var C={sourceLanguage:google.elements.transliteration.LanguageCode.ENGLISH,destinationLanguage:google.elements.transliteration.LanguageCode.HINDI,shortcutKey:"ctrl+g",transliterationEnabled:false};var E=new google.elements.transliteration.TransliterationControl(C);E.makeTransliteratable(D);if(F){var A=document.getElementById(F);E.addEventListener(google.elements.transliteration.TransliterationControl.EventType.STATE_CHANGED,function(G){A.checked=G.transliterationEnabled});A.checked=E.isTransliterationEnabled();Minglebox.addListener(A,"click",function(){E.toggleTransliteration()},this)}E.showControl(B,{controlType:google.elements.transliteration.TransliterationControl.ControlType.MULTI_LANGUAGE_BUTTON})}Minglebox.Prompter=function(D){var B=D.parentNode?D.parentNode.getElementsByTagName("span"):null;this.inputElement=D;this.promptElement=null;this.prompt="";if(B&&B.length>0){for(var A=0;A<B.length;A++){if(B[A].className=="hint"){this.promptElement=B[A];break}}}if(this.inputElement.type.toLowerCase()=="text"||this.inputElement.tagName.toLowerCase()=="textarea"){var C=this.promptElement?this.promptElement.getAttribute("prompt"):null;if(C){this.prompt=C}else{C=this.inputElement.getAttribute("prompt");this.prompt=C?C:null}}if(this.prompt&&!this.inputElement.value){this.inputElement.value=this.prompt}Minglebox.addListener(this.inputElement,"focus",function(F,E){if(E.prompt&&E.inputElement.value==E.prompt){if(E.inputElement.type.toLowerCase()=="text"||E.inputElement.tagName.toLowerCase()=="textarea"){E.inputElement.value=""}}if(E.promptElement){E.promptElement.style.display="inline";E.promptElement.style.marginTop=(0-(E.promptElement.clientHeight+2))+"px";window.setTimeout(function(){E.promptElement.style.display="none"},3000)}},this);Minglebox.addListener(this.inputElement,"blur",function(F,E){if(E.prompt&&E.inputElement.value==""){if(E.inputElement.type.toLowerCase()=="text"||E.inputElement.tagName.toLowerCase()=="textarea"){E.inputElement.value=E.prompt}}if(E.promptElement){E.promptElement.style.display="none"}},this);if(this.inputElement.form){Minglebox.addListener(this.inputElement.form,"submit",function(F,E){if(E.prompt&&E.inputElement.value==E.prompt){if(E.inputElement.type.toLowerCase()=="text"||E.inputElement.tagName.toLowerCase()=="textarea"){E.inputElement.value=""}}},this)}};function prepareInputsForHints(){var A=document.getElementsByTagName("input");for(var D=0;D<A.length;D++){new Minglebox.Prompter(A[D])}var A=document.getElementsByTagName("textarea");for(var D=0;D<A.length;D++){new Minglebox.Prompter(A[D])}var C=document.getElementsByTagName("select");for(var B=0;B<C.length;B++){new Minglebox.Prompter(C[D])}}function prepareInputsForHints1(){var D=document.getElementsByTagName("input");var C="";var H=false;for(var G=0;G<D.length;G++){var A=D[G].parentNode.getElementsByTagName("span");if(A&&A.length>0&&A[0].className=="hint"){if(D[G].type=="text"){H=true}D[G].onfocus=function(){if(H){C=this.value;this.value=""}this.parentNode.getElementsByTagName("span")[0].style.display="inline"};D[G].onblur=function(){this.parentNode.getElementsByTagName("span")[0].style.display="none";if(H){if(this.value==""){this.value=C}}}}}var F=document.getElementsByTagName("select");for(var E=0;E<F.length;E++){var B=F[E].parentNode.getElementsByTagName("span");if(B&&B.length>0&&B[0].className=="hint"){F[E].onfocus=function(){this.parentNode.getElementsByTagName("span")[0].style.display="inline"};F[E].onblur=function(){this.parentNode.getElementsByTagName("span")[0].style.display="none"}}}}Function.prototype.inherits=function(A){function B(){}B.prototype=A.prototype;this.superClass_=A.prototype;this.prototype=new B();this.prototype.constructor=this};function tagsEdited(B,A){var F=document.getElementsByName("tag")[0].value;var C=F.split(" ");var G="";for(var E=0;E<C.length;E++){if(G.length>0){G=G+" "}G=G+'<a href="'+B+C[E]+'" target="_parent">'+C[E]+"</a>"}if(A.status=="success"){var D=document.getElementById("tagsDiv");if(D){D.innerHTML=G}}mb._get("addTagLayer").style.display="none";document.getElementsByName("tag")[0].value=F}function submitPhotoForm(B){var A=new AjaxFileUpload(B,phUploadCallback,null);A.start()}function validateRfiForStudyAbroad(){var J="Name *";var D="E-mail Address *";var K="Contact Number *";var H="your query here...";var C="Location *";var I=document.getElementById("rfiFormEx");var A=I.name.value;var F=I.email.value;var E=I.contactNumber.value;var G=I.query.value;var B=I.preferredLocation.value;if(A==J){alert("Please provide your name");I.name.focus();return false}if(F==D){alert("Please provide your email");I.email.focus();return false}if(!(checkemail(I,F))){return false}if(E==K){alert("Please provide your contact number");I.contactNumber.focus();return false}if((E==null)||(E=="")){alert("Please provide your contact number");I.contactNumber.focus();return false}if(checkInternationalPhone(E)==false){alert("Please provide a valid phone number");I.contactNumber.value="";I.contactNumber.focus();return false}if(B=="other"||B==""||B==C){alert("Please provide your Study Location");I.prefLoc.focus();return false}if(G==H){alert("Please provide us with relevant details of your query");I.query.focus();return false}document.getElementById("btnsbmt").style.display="none";document.getElementById("btnprcs").style.display="block";return true}function validateQnARfiForStudyAbroad(){var K="Name *";var D="E-mail Address *";var L="Contact Number *";var I="Type your Question here...";var C="Location *";var J=document.getElementById("rfiFormEx");var A=J.name.value;var F=J.email.value;var E=J.contactNumber.value;var G=J.query.value;var H=J.prefLoc.value;var B=J.preferredLocation.value;if(A==K){alert("Please provide your name");J.name.focus();return false}if(F==D){alert("Please provide your email");J.email.focus();return false}if(!(checkemail(J,F))){return false}if(E==L){alert("Please provide your contact number");J.contactNumber.focus();return false}if((E==null)||(E=="")){alert("Please provide your contact number");J.contactNumber.focus();return false}if(checkInternationalPhone(E)==false){alert("Please provide a valid phone number");J.contactNumber.value="";J.contactNumber.focus();return false}if(B=="other"||B==""||B==C){alert("Please provide your Study Preference");J.prefLoc.focus();return false}if(G==I){alert("Please provide us with relevant details of your query");J.query.focus();return false}document.getElementById("btnsbmt").style.display="none";document.getElementById("btnprcs").style.display="inline";return true}function showOtherLocation(){var A=document.getElementById("prefLoc").value;document.getElementById("preferredLocation").value=A;if((A=="other")){document.getElementById("otherLoc").style.display="block"}else{document.getElementById("otherLoc").style.display="none"}}function showOtherLocationQnA(){var A=document.getElementById("prefLoc").value;document.getElementById("preferredLocation").value=A;if((A=="other")){document.getElementById("otherLoc").style.display="inline"}else{document.getElementById("otherLoc").style.display="none"}}function changeLocation(){document.getElementById("preferredLocation").value=document.getElementById("otherLocation").value}var states=new Array("Andaman and Nicobar Islands","Andhra Pradesh","Arunachal Pradesh","Assam","Bihar","Chandigarh","Chhattisgarh","Dadra and Nagar Haveli","Daman and Diu","Delhi","Goa","Gujarat","Haryana","Himachal Pradesh","Jammu and Kashmir","Jharkhand","Karnataka","Kerala","Lakshadweep","Pondicherry","Madhya Pradesh","Maharashtra","Manipur","Meghalaya","Mizoram","Nagaland","Orissa","Punjab","Rajasthan","Sikkim","Tamil Nadu","Tripura","Uttar Pradesh","Uttaranchal","West Bengal");var cities=new Array();cities["Andaman and Nicobar Islands"]=new Array("Port Blair");cities["Andhra Pradesh"]=new Array("Adilabad","Adoni","Amalapuram","Anakapalle","Anantapur ","Anaparthy","Armur","Bhimavaram","Chittoor","Cuddapah","Dharmavaram","Eluru","Gadwal","Gudivada","Gudur","Guntakal","Guntur","Hindupur","Hyderabad","Jangaon","Jangareddygudem","Kakinada","Kandukur","Karimnagar","Kavali","Khammam","Krishna","Kurnool","Mahbubnagar","Medak","Naidupeta","Nalgonda","Nandyal","Narasaraopet","Narsampet","Nellore","Nizamabad","Palasa","Peddapuram","Prakasam","Rajahmundry","Rajampet,Cuddapah","Ramachandrapuram","Secunderabad","Siddipet ","Srikakulam","Tanuku","Tirupathi","Vijaywada","Vishakhapatnam","Vizianagaram","Warangal","West Godavari","Zahirabad");cities["Arunachal Pradesh"]=new Array("Itanagar","Papumpare");cities.Assam=new Array("Barpeta","Dhuliajaan","Dibrugarh","Guwahati","Jorhat","Karimganj","Nagaon","Sibsagar","Silchar","Tezpur","Tinsukia");cities.Bihar=new Array("Arrah","Begusarai","Bhagalpur","Buxar ","Chapra","Darbhanga","Gaya","Gopalganj","Muzaffarpur","Patna","Purnia");cities.Chandigarh=new Array("Chandigarh");cities.Chhattisgarh=new Array("Ambikapur","Bhillai","Bilaspur","Dhamtari","Durg","Kawardha","Korba","Mahasamund","Raigarh","Raipur","Rajnandgaon");cities["Dadra and Nagar Haveli"]=new Array("Amli","Silvassa");cities["Daman and Diu"]=new Array("Daman","Diu");cities.Delhi=new Array("New Delhi");cities.Goa=new Array("Mapusa","Margao","Panaji","Ponda","Vasco Da Gama");cities.Gujarat=new Array("Ahmedabad","Amreli","Anand","Ankleshwar","Baroda","Bavla","Bharuch","Bhavnagar","Bhuj","Borsad","Dahod","Deesa","Gandhidham","Gandhinagar","Godhra","Hazira","Himmatnagar","Jamnagar","Junagadh","Kapadvanj","Mehsana","Modasa","Mundra","Nadiad","Navsari","Palanpur","Patan","Porbandar","Rajkot","Surat","Surendranagar","Unjha","Vallabh Vidyanagar","Valsad","Vapi","Viramgam");cities.Haryana=new Array("Agroha","Ambala","Bhiwani","Chika,Kaithal","Faridabad","Fatehabad","Gohana","Gurgaon","Hissar","Jind","Kaithal","Karnal","Kurukshetra","Palwal","Panchkula","Panipat","Pehowa","Pipli","Rewari","Rohtak","Sirsa","Sonipat","Yamunanagar");cities["Himachal Pradesh"]=new Array("Baddi","Bilaspur","Dharmshala","Hamirpur","Kulu","Mandi","Nahan","Palampur","Shimla","Solan","Una");cities["Jammu and Kashmir"]=new Array("Jammu","Samba","Srinagar","Udhampur");cities.Jharkhand=new Array("Bokaro","Chaibasa","Daltonganj","Deoghar","Dhanbad","Giridih","Godda","Gumla","Hazaribag","Jamshedpur","Jhumri Talaiya","Ranchi","Toramdih");cities.Karnataka=new Array("Bagalkot","Bangalore","Bangalore Urban","Bangarapet","Belgaum","Bidar","Bijapur","Boragaon","Chikmagalur","Davanagere","Dharwad","Gadag","Gangavathy","Gulbarga","Haveri","Hosur","Hubli","Kollegal","Kushalnagar","Madikeri","Mandya","Mangalore","Manipal","Mysore","Raichur","Shahapur","Shimoga","Sindhanur","Sirsi");cities.Kerala=new Array("Adoor","Alappuzha","Aluva","Angamaly","Calicut","Changanacherry","Chenganur","Cochin","Ernakulam","Guruvayur","Idukki","Irinjalakuda","Kalpetta","Kanjirapally","Kannur","Karunagapally","Kasargode","Kochi","Kollam","Kothamangalam","Kottakal","Kottarakkara","Kottayam","Kozhikode","Kumbanad","Kunnamangalam","Kunnamkulam","Malappuram","Manjeri","Mavelikkara","Muvattupuzha","Palai","Palakkad","Pathanamthitta","Perinthalmanna","Thalassery","Thiruvalla","Thiruvananthapuram","Thodupuzha","Thrissur","Tirur","Trivandrum","Vadakara");cities.Lakshadweep=new Array("Kavaratti","Minicoy");cities["Madhya Pradesh"]=new Array("Barwani","Betul","Bhopal","Chhatarpur","Chhindwara","Damoh","Dewas","Dhar","Gwalior","Harda","Hoshangabad","Indore","Jabalpur","Jhansi","Khandwa","Khargone","Mandsaur","Morena","Raisen","Rajgarh","Ratlam","Rewa","Sagar","Satna","Sehore","Seoni","Shajapur","Sidhi","Ujjain","Vidisha");cities.Maharashtra=new Array("Ahmednagar","Akola","Alibag","Amravati","Ankalkhop","Aurangabad","Bedag","Bhandara","Bijapore","Bilur","Boisar","Buldhana","Chandrapur","Chinchwad","Dahanu","Dhule","Dighanchi","Hatkanangale","Hingoli","Ichalkaranji","Jalgaon","Jalna","Jath","Kalyan Dombivli","Kavalapur","Kavathe Mahankal ","Khamgaon","Khandala","Kolhapur","Kukudwad","Latur","Malegaon","Manerajuri","Mangaon","Miraj","Mumbai","Nagpur","Nanded","Nandurbar","Narwad","Nashik","Navi Mumbai","Nazare","Palghar","Pandharpur","Panvel","Parbhani","Pune","Raigad","Raigarh","Ratnagiri","Rethare Harnaksha","Salgare","Sangli","Sangliwadi","Satara","Savalaj","Sawantwadi","Shirol","Shirpur","Shrirampur","Sinner","Solapur","Talegaon Dabhade","Tasgaon","Thane","Tikondi","Tung","Udgaon","Umarani","Uran - Islampur ","Vita","Wani","Washim");cities.Manipur=new Array("Bishnupur","Imphal","Kakching","Mayang Imphal","Thoubal");cities.Meghalaya=new Array("Jowai","Shilong","Tura");cities.Mizoram=new Array("Aizwal");cities.Nagaland=new Array("Dimapur","Kohima");cities.Orissa=new Array("Angul","Balangir","Baleshwar","Barbil","Bargarh","Behrampur","Bhadrak","Bhubaneshwar","Choudwar","Cuttack","Jagatsinghpur","Jaleswar","Jeypore","Jharsuguda","Kendrapara","Keonjhar","Khordha","Nayagarh","Paralakhemundi","Puri","Rairangpur","Rourkela","Sambalpur","Sundergarh ","Umarkote");cities.Pondicherry=new Array("Pondicherry");cities.Punjab=new Array("Ahmedgarh","Ambala","Amritsar","Bhatinda","Derabassi","Faridkot","Fatehgarh Sahib","Ferozpur","Gurdaspur","Hoshiarpur","Jagroan","Jalandhar","Kapurthala","Khanna","Kharar","Kotkapura","Ludhiana","Mansa","Moga","Mohali","Mukerian","Muktsar","Nabha","Nakodar","Nawanshahar","Nurmahal","Pathankot","Patiala","Phagwara","phillaur","Rajpura","Roopnagar","Sangrur");cities.Rajasthan=new Array("Ajmer","Alwar","Balotra","Banswara","Baran","Behror","Bharatpur","Bhilwara","Bikaner","Bundi","Churu","Dausa","Dungarpur","Hanumangarh","Jaipur","Jaisalmer","Jalore","Jhalawar","Jodhpur","Karauli","Kota","Kotputli","Merta City","Nagaur","Pali","Rajsamand","Sikar","Udaipur");cities.Sikkim=new Array("Gangtok");cities["Tamil Nadu"]=new Array("Achampathu","Alangudi","Alathiyur","Alavakotti","Amaravathipudur","Aranthangi","Ariyalur","AthikadduThekkur","Athikkadai","Attur","Avinangudi","Avinipatti","Chatrapatti","Chengalpet","Chennai","Coimbatore","Coonoor","Cuddalore","Devakottai","Devikapuram","Devipattinam","Dharapuram","Dharmapuri","Dindigul","Elathur","Embal","Eriyur","Erode","Gobichettipalayam","Idappadi","Irulapatty","Kadaladi","Kallakurichi","Kallal","Kancheepuram","Kandanur","Kandavarayanpatti","Karaikal","Karaikudi","Karaiyur","Karur","Kavalkinaru","Kayalpattinam","Keelakarai","Keelavalaru","Keeranur","Kodaikanal","Kodumudi","Kollidam","Konapet","Koothanallur","Koppanapatti","Kothamangalam","Kottaipattinam","Kottaiyur","Krishnagiri","Kulipirai","Kumaravelur","Kumbakonam","Madurai","Mahipalanpatti","Malaiyur","Mallikapuram","Mannargudi","Mayiladuthurai","Melalokkur","Melapavoor","Melasivapuri","Mellur","Modaiyur","Muraiyur","Muthupet","Nachandupatti","Nagapattinam","Nagercoil","Namakkal","Nattarasankottai","Nemathanpatti","Neyveli","OyyakandanSiruvayal","Paganeri","Palani","Palavangudi","Panaikulam","Panayapatti","Panruti","Paramakudi","Pattamadi","Pattipulam","Pattukottai","Pavithram","Peddur","Pennadam","Peralam","Periyakulam","PillamanklamAlagapuri","Pollachi","Ponbethi","Ponnamaravathy","Poolampatti","Portonova","Pudukottai","Pulankurichi","Puliyur","Rajapalayam","Ramanathapuram","Ramapattinam","Rangiem","Ravanasamudram","Rayavaram","Reddiarchatram","Salem","Samayanallur","Sankarapuram","Saram","Sathyamangalam","Sholavandan","Singampunari","Siruvachoor","Sithilingamadam","Sivaganga","Sivakasi","Sokkanathapuram","Srirangam","Sundarapandipuram","Tanjore","Tenkasi","Theni","Thiruparamkundram","Thiruvannamalai","Thiruvarur","Thottipatti","Thriumuruganpoondi","Tindivanam","Tiruchendur","Tirumangalam","Tirunelveli","Tirupattur","Tiruppur","Tiruvalam","Trichy","Tuticorin","Udumalpet","Vadakkankulam","Valoothoor","Vanavasi","Vaniyambadi","Vellalur","Vellanur","Vellore","Vemandampalayam","Vengur","Vettaikaranpudur","Villupuram","Virachilai","Virudhachalam","Virudhunagar");cities.Tripura=new Array("Agartala");cities["Uttar Pradesh"]=new Array("Agra","Aligarh","Allahabad","Almora","Azamgarh","Ballia","Balrampur","Barabanki","Bareilly","Basti","Bhadohi","Bijnor","Biswan","Chandpur","Deoria","Faizabad","Firozabad","Ghaziabad","Ghazipur","Gola Bazar","Gorakhpur","Haidergarh","Haldwani","Hardoi","Hathras","Jais","Jaunpur","Kanpur","Kashipur","Khurja","Lucknow","Mathura","Mau","Meerut","Moradabad","Muzaffarnagar","Nainital","Noida","Pilibhit","Pratapgarh","Rai Bareli","Rampur","Robertsganj","Saharanpur","Sayed Raja ","Shahganj ","Shahjahanpur","Shamli","Sultanpur","Udham Singhnagar","Varanasi");cities.Uttaranchal=new Array("Badrinath","Dehradun","Gopeshwar","Haridwar","Kalagarh","Kotdwara","Mussoorie","Pauri Garhwal","Rishikesh","Roorkee","Sri Nagar","Tehri","Uttarkashi");cities["West Bengal"]=new Array("Alipurduar","Arambag","Asansol","Balurghat","Barasat","Birbhum","Bishnupur","Burdwan","Chandannagar","Dalkhola","Darjeeling","Durgapur","Howrah","Jalpaiguri","Kalimpong","Kalna","Kalyani","Kharagpur","Koch Bihar","Kolkata","Maldah","Medinipur","Memari","Murshidabad","Pandua","Puruliya","Rishra","Siliguri","Tamluk","Uttar Dinajpur","Uttarpara");function setStates(E,B,D,C,A){changeSelect(E,B,states,states);setCities(B,D,C,A)}function setCities(B,E,D,A){if(B!=""){var C=cities[B];(document.getElementById(A)).style.display="inline-block"}else{(document.getElementById(A)).style.display="none"}changeSelect(E,D,C,C)}function changeSelect(B,D,F,C){var E=document.getElementById(B);E.options.length=0;E.options[0]=new Option("Select ...","");for(i=0;i<F.length;i++){E.options[E.length]=new Option(F[i],C[i])}var A=getIndex(F,D);if(A>=0){E.selectedIndex=A+1}}function getIndex(B,A){if(A!=null&&A!=""){return B.indexOf(A)}return -1}function validateRfi1(){var F=document.getElementById("rfiFormEx1");var E=F.name.value;var D=F.email.value;var A=F.contactNumber.value;var G=F.city.value;var B=F.preferredLocation.value;var C="Location *";if(E==null||E==""){alert("Please provide your name");F.name.focus();return false}if(D==null||D==""){alert("Please provide your email");F.email.focus();return false}if(!(checkemail(F,D))){return false}if(A==null||A==""){alert("Please provide your contact number");F.contactNumber.focus();return false}if((G==null)||(G=="")){alert("Please provide your city");F.city.focus();return false}if(B=="none"||B==""||B==C){alert("Please provide your Study Location");F.preferredLocation.focus();return false}if(checkInternationalPhone(A)==false){alert("Please provide a valid phone number");F.contactNumber.value="";F.contactNumber.focus();return false}return true}function validateRfi2(){var D=document.getElementById("rfiFormEx1");var C=D.name.value;var B=D.email.value;var A=D.contactNumber.value;var E=D.city.value;if(C==null||C==""){alert("Please provide your name");D.name.focus();return false}if(B==null||B==""){alert("Please provide your email");D.email.focus();return false}if(!(checkemail(D,B))){return false}if(A==null||A==""){alert("Please provide your contact number");D.contactNumber.focus();return false}if((E==null)||(E=="")){alert("Please provide your city");D.city.focus();return false}if(checkInternationalPhone(A)==false){alert("Please provide a valid phone number");D.contactNumber.value="";D.contactNumber.focus();return false}document.getElementById("btnsbmt").style.display="none";document.getElementById("btnprcs").style.display="inline-block";return true}function validateCatRfi(){var H="Name *";var E="E-mail Address *";var G="Contact Number *";var F="City *";var D=document.getElementById("rfiFormEx1");var C=D.name.value;var B=D.email.value;var A=D.contactNumber.value;if(C==H){alert("Please provide your name");D.name.focus();return false}if(B==E){alert("Please provide your email");D.email.focus();return false}if(!(checkemail(D,B))){return false}if(A==G){alert("Please provide your contact number");D.contactNumber.focus();return false}if((A==null)||(A=="")){alert("Please provide your contact number");D.contactNumber.focus();return false}if(checkInternationalPhone(A)==false){alert("Please provide a valid phone number");D.contactNumber.value="";D.contactNumber.focus();return false}document.getElementById("btnsbmt").style.display="none";document.getElementById("btnprcs").style.display="inline";return true}function catRfiCallback(B,C){if(C.status=="success"){var A=B?mb._get(B):null;if(A){A.innerHTML="Thanks for registering"}else{alert("Thanks for registering")}clearCatRfiData()}}function clearCatRfiData(){var A=document.getElementById("rfiFormEx1");A.name.value=A.nmVal.value;A.email.value=A.emailVal.value;A.contactNumber.value=A.mobVal.value;setTimeout(clearRfi,1000)}function changeEnggRankFilters(){var A=document.getElementById("exam").value;if(A=="AIEEE"){document.getElementById("aieee").style.display="block";document.getElementById("eamcet").style.display="none";document.getElementById("tnea").style.display="none";document.getElementById("upsee").style.display="none"}if(A=="EAMCET"){document.getElementById("aieee").style.display="none";document.getElementById("eamcet").style.display="block";document.getElementById("tnea").style.display="none";document.getElementById("upsee").style.display="none"}if(A=="TNEA"){document.getElementById("aieee").style.display="none";document.getElementById("eamcet").style.display="none";document.getElementById("tnea").style.display="block";document.getElementById("upsee").style.display="none"}if(A=="UPSEE"){document.getElementById("aieee").style.display="none";document.getElementById("eamcet").style.display="none";document.getElementById("tnea").style.display="none";document.getElementById("upsee").style.display="block"}}function submitEnggRankSearch(){var D=document.getElementById("exam").value;var H=document.getElementById("year").value;var G=document.getElementById("rank").value;var C=document.getElementById(D+"-category").value;var A=document.getElementById(D+"-state").value;var I=document.getElementById(D+"-gender").value;var J=document.getElementById(D+"-branch").value;var B="/open-close-ranks/"+D+"/"+H;if(G!=null&&G!=""){B=B+"/"+G}else{B=B+"/1"}if(C!=null&&C!=""){B=B+"/"+C}else{B=B+"/-"}if(A!=null&&A!=""){B=B+"/"+A}else{B=B+"/-"}if(I!=null&&I!=""){B=B+"/"+I}else{B=B+"/-"}if(J!=null&&J!=""){var K=document.getElementById(D+"-branch");var E=0;var J;for(var F=0;F<K.options.length;F++){if(K.options[F].selected==true){if(E++==0){J=K.options[F].value}else{J=J+";"+K.options[F].value}}}if(J!=null&&J!=""){B=B+"/"+J}}else{B=B+"/-"}window.location.href=B}function Animation(A){if(this==window){return new Animation(A)}else{this.obj=A;this._reset_state();this.queue=[];this.last_attr=null}}Animation.resolution=20;Animation.offset=0;Animation.prototype._reset_state=function(){this.state={attrs:{},duration:500}};Animation.prototype.stop=function(){this._reset_state();this.queue=[];return this};Animation.prototype._build_container=function(){if(this.container_div){this._refresh_container();return }if(this.obj.firstChild&&this.obj.firstChild.__animation_refs){this.container_div=this.obj.firstChild;this.container_div.__animation_refs++;this._refresh_container();return }var A=document.createElement("div");A.style.padding="0px";A.style.margin="0px";A.style.border="0px";A.__animation_refs=1;var B=this.obj.childNodes;while(B.length){A.appendChild(B[0])}this.obj.appendChild(A);this.obj.style.overflow="hidden";this.container_div=A;this._refresh_container()};Animation.prototype._refresh_container=function(){this.container_div.style.height="auto";this.container_div.style.width="auto";this.container_div.style.height=this.container_div.offsetHeight+"px";this.container_div.style.width=this.container_div.offsetWidth+"px"};Animation.prototype._destroy_container=function(){if(!this.container_div){return }if(!--this.container_div.__animation_refs){var A=this.container_div.childNodes;while(A.length){this.obj.appendChild(A[0])}this.obj.removeChild(this.container_div)}this.container_div=null};Animation.ATTR_TO=1;Animation.ATTR_BY=2;Animation.ATTR_FROM=3;Animation.prototype._attr=function(A,B,C){A=A.replace(/-[a-z]/gi,function(E){return E.substring(1).toUpperCase()});var D=false;switch(A){case"background":this._attr("backgroundColor",B,C);return this;case"margin":B=Animation.parse_group(B);this._attr("marginBottom",B[0],C);this._attr("marginLeft",B[1],C);this._attr("marginRight",B[2],C);this._attr("marginTop",B[3],C);return this;case"padding":B=Animation.parse_group(B);this._attr("paddingBottom",B[0],C);this._attr("paddingLeft",B[1],C);this._attr("paddingRight",B[2],C);this._attr("paddingTop",B[3],C);return this;case"backgroundColor":case"borderColor":case"color":B=Animation.parse_color(B);break;case"opacity":B=parseFloat(B,10);break;case"height":case"width":if(B=="auto"){D=true}else{B=parseInt(B,10)}break;case"borderWidth":case"lineHeight":case"fontSize":case"marginBottom":case"marginLeft":case"marginRight":case"marginTop":case"paddingBottom":case"paddingLeft":case"paddingRight":case"paddingTop":case"bottom":case"left":case"right":case"top":case"scrollTop":case"scrollLeft":B=parseInt(B,10);break;default:throw new Error(A+" is not a supported attribute!")}if(this.state.attrs[A]===undefined){this.state.attrs[A]={}}if(D){this.state.attrs[A].auto=true}switch(C){case Animation.ATTR_FROM:this.state.attrs[A].start=B;break;case Animation.ATTR_BY:this.state.attrs[A].by=true;case Animation.ATTR_TO:this.state.attrs[A].value=B;break}};Animation.prototype.to=function(A,B){if(B===undefined){this._attr(this.last_attr,A,Animation.ATTR_TO)}else{this._attr(A,B,Animation.ATTR_TO);this.last_attr=A}return this};Animation.prototype.by=function(A,B){if(B===undefined){this._attr(this.last_attr,A,Animation.ATTR_BY)}else{this._attr(A,B,Animation.ATTR_BY);this.last_attr=A}return this};Animation.prototype.from=function(A,B){if(B===undefined){this._attr(this.last_attr,A,Animation.ATTR_FROM)}else{this._attr(A,B,Animation.ATTR_FROM);this.last_attr=A}return this};Animation.prototype.duration=function(A){this.state.duration=A?A:0;return this};Animation.prototype.checkpoint=function(B,A){if(B===undefined){B=1}this.state.checkpoint=B;this.state.checkpointcb=A;this.queue.push(this.state);this._reset_state();return this};Animation.prototype.blind=function(){this.state.blind=true;return this};Animation.prototype.hide=function(){this.state.hide=true;return this};Animation.prototype.show=function(){this.state.show=true;return this};Animation.prototype.ease=function(A){this.state.ease=A;return this};Animation.prototype.go=function(){var B=(new Date()).getTime();this.queue.push(this.state);for(var A=0;A<this.queue.length;A++){this.queue[A].start=B-Animation.offset;if(this.queue[A].checkpoint){B+=this.queue[A].checkpoint*this.queue[A].duration}}Animation.push(this);return this};Animation.prototype._frame=function(D){var E=true;var F=false;var K=false;for(var G=0;G<this.queue.length;G++){var O=this.queue[G];if(O.start>D){E=false;continue}else{if(O.checkpointcb&&(O.checkpoint*O.duration+O.start>D)){this._callback(O.checkpointcb,D-O.start-O.checkpoint*O.duration);O.checkpointcb=null}}if(O.started===undefined){if(O.show){this.obj.style.display="block"}for(var M in O.attrs){if(O.attrs[M].start!==undefined){continue}switch(M){case"backgroundColor":case"borderColor":case"color":var C=Animation.parse_color(Animation.get_style(this.obj,M=="borderColor"?"borderLeftColor":M));if(O.attrs[M].by){O.attrs[M].value[0]=Math.min(255,Math.max(0,O.attrs[M].value[0]+C[0]));O.attrs[M].value[1]=Math.min(255,Math.max(0,O.attrs[M].value[1]+C[1]));O.attrs[M].value[2]=Math.min(255,Math.max(0,O.attrs[M].value[2]+C[2]))}break;case"opacity":var C=((C=Animation.get_style(this.obj,"opacity"))&&parseFloat(C))||((C=Animation.get_style(this.obj,"opacity"))&&(C=/(\d+(?:\.\d+)?)/.exec(C))&&parseFloat(C.pop())/100)||1;if(O.attrs[M].by){O.attrs[M].value=Math.min(1,Math.max(0,O.attrs[M].value+C))}break;case"height":case"width":var C=Animation["get_"+M](this.obj);if(O.attrs[M].by){O.attrs[M].value+=C}break;case"scrollLeft":case"scrollTop":var C=(this.obj==document.body)?(document.documentElement[M]||document.body[M]):this.obj[M];if(O.attrs[M].by){O.attrs[M].value+=C}O["last"+M]=C;break;default:var C=parseInt(Animation.get_style(this.obj,M),10);if(O.attrs[M].by){O.attrs[M].value+=C}break}O.attrs[M].start=C}if((O.attrs.height&&O.attrs.height.auto)||(O.attrs.width&&O.attrs.width.auto)){if(/Firefox\/[12]\./.test(navigator.userAgent)){K=true}this._destroy_container();for(var M in {height:1,width:1,fontSize:1,borderLeftWidth:1,borderRightWidth:1,borderTopWidth:1,borderBottomWidth:1,paddingLeft:1,paddingRight:1,paddingTop:1,paddingBottom:1}){if(O.attrs[M]){this.obj.style[M]=O.attrs[M].value+(typeof O.attrs[M].value=="number"?"px":"")}}if(O.attrs.height&&O.attrs.height.auto){O.attrs.height.value=Animation.get_height(this.obj)}if(O.attrs.width&&O.attrs.width.auto){O.attrs.width.value=Animation.get_width(this.obj)}}O.started=true;if(O.blind){this._build_container()}}var B=(D-O.start)/O.duration;if(B>=1){B=1;if(O.hide){this.obj.style.display="none"}}else{E=false}var L=O.ease?O.ease(B):B;if(!F&&B!=1&&O.blind){F=true}if(K&&this.obj.parentNode){var H=this.obj.parentNode;var A=this.obj.nextSibling;H.removeChild(this.obj)}for(var M in O.attrs){switch(M){case"backgroundColor":case"borderColor":case"color":this.obj.style[M]="rgb("+Animation.calc_tween(L,O.attrs[M].start[0],O.attrs[M].value[0],true)+","+Animation.calc_tween(L,O.attrs[M].start[1],O.attrs[M].value[1],true)+","+Animation.calc_tween(L,O.attrs[M].start[2],O.attrs[M].value[2],true)+")";break;case"opacity":var I=Animation.calc_tween(L,O.attrs[M].start,O.attrs[M].value);try{this.obj.style.opacity=(I==1?"":I);this.obj.style.filter=(I==1?"":"alpha(opacity="+I*100+")")}catch(J){}break;case"height":case"width":this.obj.style[M]=L==1&&O.attrs[M].auto?"auto":Animation.calc_tween(L,O.attrs[M].start,O.attrs[M].value,true)+"px";break;case"scrollLeft":case"scrollTop":var C=(this.obj==document.body)?(document.documentElement[M]||document.body[M]):this.obj[M];if(O["last"+M]!=C){delete O.attrs[M]}else{var N=Animation.calc_tween(L,O.attrs[M].start,O.attrs[M].value,true)-C;if(M=="scrollLeft"){window.scrollBy(N,0)}else{window.scrollBy(0,N)}O["last"+M]=N+C}break;default:this.obj.style[M]=Animation.calc_tween(L,O.attrs[M].start,O.attrs[M].value,true)+"px";break}}if(B==1){this.queue.splice(G--,1);this._callback(O.ondone,D-O.start-O.duration)}}if(K){H[A?"insertBefore":"appendChild"](this.obj,A)}if(!F&&this.container_div){this._destroy_container()}return !E};Animation.prototype.ondone=function(A){this.state.ondone=A;return this};Animation.prototype._callback=function(B,A){if(B){Animation.offset=A;B.call(this);Animation.offset=0}};Animation.calc_tween=function(B,D,C,A){return(A?parseInt:parseFloat)((C-D)*B+D,10)};Animation.parse_color=function(A){var C=/^#([a-f0-9]{1,2})([a-f0-9]{1,2})([a-f0-9]{1,2})$/i.exec(A);if(C){return[parseInt(C[1].length==1?C[1]+C[1]:C[1],16),parseInt(C[2].length==1?C[2]+C[2]:C[2],16),parseInt(C[3].length==1?C[3]+C[3]:C[3],16)]}else{var B=/^rgba? *\(([0-9]+), *([0-9]+), *([0-9]+)(?:, *([0-9]+))?\)$/.exec(A);if(B){if(B[4]==="0"){return[255,255,255]}else{return[parseInt(B[1],10),parseInt(B[2],10),parseInt(B[3],10)]}}else{if(A=="transparent"){return[255,255,255]}else{throw"Named color attributes are not supported."}}}};Animation.parse_group=function(A){var A=trim(A).split(/ +/);if(A.length==4){return A}else{if(A.length==3){return[A[0],A[1],A[2],A[1]]}else{if(A.length==2){return[A[0],A[1],A[0],A[1]]}else{return[A[0],A[0],A[0],A[0]]}}}};Animation.get_height=function(D){var C=parseInt(Animation.get_style(D,"paddingTop"),10),B=parseInt(Animation.get_style(D,"paddingBottom"),10),A=parseInt(Animation.get_style(D,"borderTopWidth"),10),E=parseInt(Animation.get_style(D,"borderBottomWidth"),10);return D.offsetHeight-(C?C:0)-(B?B:0)-(A?A:0)-(E?E:0)};Animation.get_width=function(C){var B=parseInt(Animation.get_style(C,"paddingLeft"),10),E=parseInt(Animation.get_style(C,"paddingRight"),10),D=parseInt(Animation.get_style(C,"borderLeftWidth"),10),A=parseInt(Animation.get_style(C,"borderRightWidth"),10);return C.offsetWidth-(B?B:0)-(E?E:0)-(D?D:0)-(A?A:0)};Animation.get_style=function(B,C){var A;return(window.getComputedStyle&&window.getComputedStyle(B,null).getPropertyValue(C.replace(/[A-Z]/g,function(D){return"-"+D.toLowerCase()})))||(document.defaultView&&document.defaultView.getComputedStyle&&(A=document.defaultView.getComputedStyle(B,null))&&A.getPropertyValue(C.replace(/[A-Z]/g,function(D){return"-"+D.toLowerCase()})))||(B.currentStyle&&B.currentStyle[C])||B.style[C]};Animation.push=function(A){if(!Animation.active){Animation.active=[]}Animation.active.push(A);if(!Animation.timeout){Animation.timeout=setInterval(Animation.animate,Animation.resolution)}};Animation.animate=function(){var A=true;var C=(new Date()).getTime();for(var B=0;B<Animation.active.length;B++){if(Animation.active[B]._frame(C)){A=false}else{Animation.active.splice(B--,1)}}if(A){clearInterval(Animation.timeout);Animation.timeout=null}};Animation.ease={};Animation.ease.begin=function(A){return A*A};Animation.ease.end=function(A){A-=1;return -(A*A)+1};Animation.ease.both=function(A){if(A<=0.5){return(A*A)*2}else{A-=1;return(A*A)*-2+1}};function isIE6(){var B=navigator.appName;var C=navigator.appVersion;var A=parseFloat(C);return((B=="Microsoft Internet Explorer")&&(A<=4))}Minglebox.Menu=function(A){this.curNav=A;this.menuids=new Array("newMenu");this.lastSelectedId=false;this.initMenu();this.clicked=false;this.current=false};Minglebox.Menu.prototype={initMenu:function(){mbself=this;for(var A=0;A<this.menuids.length;A++){var C=this._gel(this.menuids[A]).getElementsByTagName("ul");var E=this._gel(this.menuids[A]).getElementsByTagName("li");for(var B=0;B<E.length;B++){if(E[B].className=="rcLink"||E[B].className=="rcHover"){var D=E[B].id;Minglebox.addListener(E[B],"mouseover",function(H){H=H||window.event;var G=mbself.checkMenuId(H,this);var F=mbself.getIEHack(H);if(G!=mbself.curNav){F.className="rcHover";mbself.clicked=false;if(this.id){document.getElementById(this.id).className="rcHover"}}});Minglebox.addListener(E[B],"mouseout",function(I){if(mbself.clicked){return }I=I||window.event;var H=mbself.checkMenuId(I,this);var G=mbself.getIEHack(I);if(H!=mbself.curNav){G.className="rcLink";var F=document.getElementById("sm_"+this.id).style.display;if(this.id!=""&&F=="none"){document.getElementById(this.id).className="rcLink"}}});Minglebox.addListener(document.getElementById("_"+D),"click",function(F){var G=this.id;if(!G){G=F.srcElement.id}F.cancelBubble=true;if(F.stopPropagation){F.stopPropagation()}if(mbself.lastSelectedId==G){mbself.removeLastSelected(mbself);mbself.setLastSelectedId(false);mbself._gel("sm"+G).parentNode.className="rcHover";mbself.clicked=false;return }mbself.removeLastSelected(mbself);mbself._gel("sm"+G).style.display="block";mbself._gel("sm"+G).parentNode.className="rcHover";mbself.setLastSelectedId(G);mbself.clicked=true})}}Minglebox.addListener(document,"click",function(G){var F=G.srcElement||G.target;mbself.removeLastSelected(mbself);mbself.clicked=false;if(F.id!=mbself.lastSelectedId){mbself.setLastSelectedId(false)}})}},setLastSelectedId:function(A){this.lastSelectedId=A},checkMenuId:function(C,B){C=C||window.event;var A=mbself.getIEHack(C);if(window.event){var D=A.getElementsByTagName("a")[0].id}else{var D=B.getElementsByTagName("a")[0].id}return D},getIEHack:function(B){var A="";if(B.srcElement){if(B.srcElement.tagName.toUpperCase()=="STRONG"){A=B.srcElement.parentNode.parentNode}else{if(B.srcElement.tagName.toUpperCase()=="A"){A=B.srcElement.parentNode}else{if(B.srcElement.tagName.toUpperCase()=="EM"){A=B.srcElement.parentNode}else{if(B.srcElement.tagName.toUpperCase()=="UL"){A=B.srcElement.firstChild}else{if(B.srcElement.tagName.toUpperCase()=="LI"){A=B.srcElement}}}}}}return A},getLastSelectedId:function(){return this.lastSelectedId},removeLastSelected:function(A){if(A.lastSelectedId){this._gel("sm"+A.lastSelectedId).style.display="none";this._gel("sm"+A.lastSelectedId).parentNode.className="rcLink"}},_gel:function(A){return document.getElementById(A)}};function fadeDiv_(C){var B=100;var A=window.setInterval(function(){B=B-10;C.style.filter="Alpha(Opacity="+B+")";C.style.opacity=B/100;if(B==0){if(C){C.style.display="none"}window.clearInterval(A)}},5);return }function launch(C){var A=1024;var B=768;if(window.screen){A=window.screen.availWidth;B=window.screen.availHeight}return !window.open(addContextPath("/otp/launch.do?method=exam&surveyId="+C),"onlinetestprep","top=0,left=0,width="+A+", height="+B+", address=no,location=no,menubar=no,status=no,toolbar=no,scrollbars=no,resizable=no,fullscreen=yes")}function showTab(C,B,D){if(C=="vTabs"){for(i=0;i<D;i++){var A="vTabLink"+(i+1);var E="vTabContent"+(i+1);document.getElementById(A).className=" ";document.getElementById(E).style.display="none"}A="vTabLink"+B;E="vTabContent"+B;document.getElementById(A).className="selectedTab";document.getElementById(E).style.display="block"}else{for(i=0;i<D;i++){A="hTabLink"+(i+1);E="hTabContent"+(i+1);document.getElementById(A).className=" ";document.getElementById(E).style.display="none"}A="hTabLink"+B;E="hTabContent"+B;document.getElementById(A).className="selectedTab";document.getElementById(E).style.display="block"}};