//Function to jump to another forum
function ForumJump(URL) {
	
	if (URL.options[URL.selectedIndex].value != "") self.location.href = URL.options[URL.selectedIndex].value;	
	return true;
}

//Function to open pop up window
function openWin(theURL,winName,features) {
  	window.open(theURL,winName,features);
}


//Function to open preview post window
function OpenPreviewWindow(targetPage, formName){
	
	now = new Date  
	
	//Open the window first 	
   	openWin('','preview','toolbar=0,location=0,status=0,menubar=0,scrollbars=1,resizable=1,width=680,height=400')
   		
   	//Now submit form to the new window
   	formName.action = targetPage + "?ID=" + now.getTime();	
	formName.target = "preview";
	formName.submit();
}


function showUserInfoBox(mID){
	b=document.getElementById("userInfoBoxDIV")
	
	document.getElementById("userInfoBoxSPAN").innerHTML=document.getElementById("im_id"+mID).innerHTML
	b.style.left=event.x+5
	b.style.top=event.y-85+document.body.scrollTop
	
}

function hideUserInfoBox(){
	document.getElementById("userInfoBoxDIV").style.left="-500"
}

function showSmileys(){
	document.getElementById("emoticonsBox").style.display="block"
}

function hideSmileys()
{

document.getElementById("emoticonsBox").style.display="none"
}

function showStatusTip(o){
	if(o.childNodes[0].tagName=='IMG')
		window.status=o.childNodes[0].alt
}

function hideStatusTip(){
	window.status=""
}
function tChart(o){

v=o.src.lastIndexOf('P')==o.src.length-1;

if(v)
	{
	
	o.src+='C'
	o.parentNode.parentNode.childNodes[0].style.position="absolute"
	o.parentNode.parentNode.childNodes[0].innerHTML="<img onclick='delFloat(this)' src='"+o.src+"'>"
	o.style.border='1px solid #737373'
	o.parentNode.parentNode.childNodes[0].style.border='1px solid #737373'
	
	
	}
else
	{
	o.style.border='none'
	o.src+='P'
	}

}

function delFloat(o){
	
	o2=o.parentNode
	o2.innerHTML="&nbsp;"
	o2.style.border='none'
	tChart(o2.parentNode.childNodes[1].childNodes[0])
}