function goto(uri)
{
	// doc root
	if (uri.charAt(0) == '/')
	{
		uri = uri.substr(1);
		path = "";
	}
	else
		path = window.location.pathname.substr(0, window.location.pathname.lastIndexOf("/"));

	// parent directories
	while (uri.substr(0, 3) == '../')
	{
		uri = uri.substr(3);
		path = path.substr(0, path.lastIndexOf("/"));
	}

	// current directory
	while (uri.substr(0, 2) == './')
		uri = uri.substr(2);

	if (uri == '.')
		uri = "";

	// assemble URL
	url = window.location.protocol + "//" + window.location.hostname +
		path + "/" + uri;

	window.location.href = url;
}


// Usage: launch('page.html','menubar=0,width=400,height=100')
function launch(url, attrib)
{
	var today = new Date();
	newwin = open(url, today.getTime(), attrib);
}

function printdate()
{
	var mthname = new Array('January','February','March',
		'April','May','June','July','August','September',
		'October','November','December');

	var date = new Date();
	var day = date.getDate();
	var mth = date.getMonth();
	var yr = date.getYear();

	return day + " " + mthname[mth] + " " + yr;
}
