
function Get_Cookie( name )
{
	var start = document.cookie.indexOf( name + "=" );
	var len = start + name.length + 1;
	if ( ( !start ) && ( name != document.cookie.substring( 0, name.length ) ) )
	{
		return null;
	}
	if ( start == -1 ) return null;
	var end = document.cookie.indexOf( ";", len );
	if ( end == -1 ) end = document.cookie.length;
	return unescape( document.cookie.substring( len, end ) );
}



function set_location(locid)
{
	document.cookie = 'loc_id='+locid.toString()+';';
	document.location=document.location;
}

function newWindow(url, name, width, height, scroll)
{
	if(width=='' && height=='')
	{
		w = window.open(url, name, 'toolbar=yes,menubar=yes,scrollbars=' + scroll + ',resizable=yes');
	}
	else
	{
		w = window.open(url, name, 'toolbar=yes,menubar=yes,scrollbars=' + scroll + ',resizable=yes,width=' + width + ',height=' + height);
	}
	w.focus();
}
