function toggleZipCode(A){if(A.options[A.selectedIndex].text=="Other"){dojo.byId("zipCodeInput").style.display="block"
}else{dojo.byId("zipCodeInput").style.display="none"
}resizePanes()
}function toggleDisplay(B,A){if(A){dojo.byId(B).style.display="block"
}else{dojo.byId(B).style.display="none"
}resizePanes()
}function showHelp(B,C){var A=dojo.byId("helpBubble");
A.style.display="block";
var D=DOMUtils.getAbsolutePos(B);
A.style.top=(D.top-10)+"px";
A.style.left=(D.left-170)+"px";
dojo.byId("helpBubbleText").innerHTML=C
}function hideHelp(){var A=dojo.byId("helpBubble");
A.style.display="none"
}function changeCaptcha(C){var B=dojo.byId(C);
var A=B.src+"1";
B.src=A
}function submitForm(A){var B=document.getElementById(A);
showFormLoading();
B.submit()
}function showRealInput(C){var A=document.getElementById("real"+C+"Div");
var D=document.getElementById("fake"+C+"Div");
var B=document.getElementById("real"+C);
D.style.display="none";
A.style.display="block";
B.value="";
B.focus()
}function clearInput(A){if(A.value=="required"){A.value=""
}A.style.color="black"
}function showFormLoading(){var A=document.getElementById("formSubmit");
var B=document.getElementById("formLoading");
A.style.display="none";
B.style.display="block";
return true
}function updateSelectColor(A){if(A.selectedIndex==-1||A.selectedIndex==0){A.style.color="#808080"
}else{A.style.color="#000000"
}}function enterKeyFilter(B,A){if(!B){B=window.event
}if(B.keyCode){keynum=B.keyCode
}else{if(B.which){keynum=B.which
}}if(keynum==13){fireClickEvent(A);
return false
}return true
}function fireClickEvent(B){var A=document.getElementById(B);
if(A!=null){if(document.all){A.fireEvent("onclick")
}else{event=document.createEvent("MouseEvents");
event.initEvent("click",true,false);
A.dispatchEvent(event)
}}}function scHover(A){document.getElementById("sc_explanation").innerHTML=A;
document.getElementById("sc_explanation").style.fontStyle="normal"
}function scClear(){document.getElementById("sc_explanation").innerHTML="roll over the icons to see what they mean";
document.getElementById("sc_explanation").style.fontStyle="italic"
}var SupportedPhones={};
SupportedPhones.showPopup=function(B,A){SupportedPhones.element=B;
this.show(A)
};
SupportedPhones.show=function(A){var B=SupportedPhones.element;
var C=DOMUtils.getAbsolutePos(B);
if(!A){var A=dojo.byId("phones_popup")
}A.style.display="block";
A.style.top=(C.top-Math.floor(A.offsetHeight/2)+20)+"px";
A.style.left=(C.left+110)+"px"
};
SupportedPhones.hide=function(){dojo.byId("sms_popup").style.display="none";
dojo.byId("phones_popup").style.display="none"
};
SupportedPhones.additionalDevices=["Apple iPhone"];
SupportedPhones.loadDevices=function(A){var B=dojo.byId("popup_content");
if(A&&A.length>0){while(B.lastChild){B.removeChild(B.lastChild)
}B.innerHTML="<h1>supported phones</h1>\n";
for(i=0;
i<this.additionalDevices.length;
i++){B.innerHTML+=this.additionalDevices[i]+"<br/>\n"
}for(i=0;
i<A.length;
i++){if(!A[i].match(/T-Mobile/)){B.innerHTML+=A[i]+"<br/>\n"
}}B.innerHTML+="<h2>more added all the time!</h2>\n"
}};
var Friends={};
Friends.people={};
Friends.toggle=function(C,B){if(this.ignore){this.ignore=false;
return 
}var A=dojo.byId("cb_"+B);
A.checked=!A.checked;
this.onClick(C,A);
this.ignore=false
};
Friends.onClick=function(B,A){if(A.checked){this.people[A.name]=true
}else{this.people[A.name]=false
}this.ignore=true
};
Friends.checkAll=function(B){var A=dojo.byId("selectFriendsForm");
for(i=0;
i<A.length;
i++){if(A[i].type=="checkbox"){A[i].checked=B;
this.onClick(null,A[i])
}}this.ignore=false
};
Friends.submit=function(){var A=dojo.byId("peopleIds");
A.value="X";
for(id in this.people){if(this.people[id]){if(A.value=="X"){A.value="S"+id
}else{A.value+=","+id
}}}if(A.value=="X"){alert("You must select at least 1 friend to connect with.");
return 
}dojo.byId("friendForm").submit()
};