var name;
function expan(name,dm){
if(dm=="qd"){		
var foto = document.getElementById(name);
foto.style.height="80px";
foto.style.width="80px";
}else{
foto = document.getElementById(name);
foto.style.height="80px";
foto.style.width="120px";	
}
}
function normalz(name,dm){
if(dm=="qd"){		
var foto = document.getElementById(name);
foto.style.height="50px";
foto.style.width="50px";
}else{
foto = document.getElementById(name);
foto.style.height="50px";
foto.style.width="90px";	
}
}
var urls;
function takemeto(urls){
document.location=urls;
}
function campic(name,pic){
document.getElementById(name).src='images/' + pic;
}
function meetvideo(class_id){


document.open('meetvideos.php?class='+ class_id,'meetvideo','left=400%,top=300%,width=500,height=400,toolbar=no,menubar=no,scrolbars=no,resizable=no,status=no,directories=no,location=no','titlebar=no');
}

var bad_car = "!#$%^&*()/\{}[]:;><`~";
function checkEmail(the_email)
{
	var the_at = the_email.indexOf("@");
	var the_dot = the_email.lastIndexOf(".");
	var a_space = the_email.indexOf(" ");
	var the_bad_at = the_email.lastIndexOf("@");
	var malo_at = the_email.substring(0,the_at);
	var check_malo= the_email.substring(0,the_bad_at);
	if ((the_at != -1) && (the_at != 0) && (the_dot != -1) && (the_dot > the_at +1) && (the_dot < the_email.length -1) && (a_space == -1) && (check_malo == malo_at) )
	{
		return true;
	}else{
		alert("Sorry, your email address is invalid!");
		return false
	}
}
function nogoodletter(test_string,illegal_string){
	var is_illegal  = false;
	var the_char = "";
	for(var loop = 0; loop < illegal_string.length; loop++){
		the_char = illegal_string.charAt(loop);
		if(test_string.indexOf(the_char) != -1){
			is_illegal = true;
		}
	}
	
	return is_illegal;
}
function countrystate(country){
if(country != "United States"){
var show = document.getElementById('states').style.visibility='hidden';
}
if(country == "United States"){
show = document.getElementById('states').style.visibility='visible';
}
}
var id, id2;
function passcher(id,id2){
var pass1 = document.getElementById(id).value;
var pass2 = document.getElementById(id2).value;
if(pass1 != pass2){
alert("Your passwords dont match");
return false;
}
if((pass1 == null) || (pass2 == null)){
alert('Please type a valid password');
return false
}
}

