function windowPop(){
	var links = document.getElementsByTagName('a');	
	for(i=0;i<links.length;i++){
		if (links[i].getAttribute('rel')=="interstitial"){
			links[i].onclick = function(){
				//top.opener.document.location=this.href;
				parent.open(this.href);
				window.close();
				return false;
			}
		}
		if (links[i].getAttribute('rel')=="popup"){
			links[i].onclick = function(){
				displayWindow(this.href,"forgot_password",475,500,"directories=0,location=0,menubar=0,resizable=0,scrollbars=0,status=0,titlebar=0,toolbar=0");
				return false;
			}
		}
	}
}
addLoadEvent(windowPop);

function leavingPop() {
	if(document.getElementById('button_register')){
		document.getElementById('button_register').onclick = function(){                               
			window.open(this.href,'leaving','width=500,height=500');
			return false;
		}
	}

}
addLoadEvent(leavingPop);

