// JavaScript Document
function ajaxSourceAndQuery(source,query){
		var pagesource = source;
		var pagequery = query;
		
		document.getElementById('login_pagesource').value = pagesource;
		document.getElementById('login_pagequery').value = pagequery;


alert(document.getElementById('login_pagesource').value+' - '+document.getElementById('login_pagequery').value);
	
	
	
	}



function getUrlQuery(){
    var query = window.location.href.slice(window.location.href.indexOf('?') + 1);
//document.getElementById('query').value = query;
	
}

function getUrlPath(){
	//var mainpath = window.location.pathname;
	var fullpath = window.location.href;
	//alert(mainpath+' '+fullpath);

	if(fullpath.indexOf('#') != -1){
			strurl = 'index.php';
		}
			else { var mainurl = window.location.hash.slice(window.location.hash.indexOf('#'));
	var strurl = mainurl.slice(0,mainurl.indexOf('?'));
	
	}
//document.getElementById('source').value = strurl;
	
}  



function assignValue(myelement, myvalue){
	document.getElementById(myelement).value = myvalue;
	}

function alertElem(myelement){
	alert(document.getElementById(myelement).value);
	}


function showAgePanel(nbr){
	
	$('#age_panel'+nbr).css({ 'display':'block'});
	$('#age_panel'+nbr).stop().animate({ 'opacity':0 }, 1);
	$('#age_panel'+nbr).stop().animate({ 'opacity':1 }, 500);

	
	}
	
	
function hideAgePanel(nbr){	
	$('#age_panel'+nbr).stop().animate({ 'opacity':0 }, 150, function(){ $('#age_panel'+nbr).css({ 'display':'none'}); });
}

function readMore(summary,full){
	document.getElementById(summary).style.display = 'none';
	document.getElementById(full).style.display = 'block';
	
	}
	
	
function readLess(summary,full){
	document.getElementById(summary).style.display = 'block';
	document.getElementById(full).style.display = 'none';
	
	}