
//Open the private messenger's window
function openPM(url) {
	if (typeof url == 'undefined')
		url = 'pm.php?action=inbox';
	
	window.open(url, 'pmessenger', 'left=300,top=200,width=650,height=500,resizable=yes,scrollbars=yes');
}


//Open a page in the parent, or use a new window if parent is unavailable
function openParent(url) {
	if (window.opener != null)
		window.opener.location = url;
	else
		window.open(url, '_blank');
}


//Insert a smiley
function InsertSmilie(smile)
{
	document.fcomment.text.value = document.fcomment.text.value + " " + smile;
	document.fcomment.text.focus();
}


//Insert a smiley
function InsertSmiliePM(smile)
{
	document.fpost.msg_body.value = document.fpost.msg_body.value + " " + smile;
	document.fpost.msg_body.focus();
}
