if (navigator.userAgent.indexOf("Opera")!=-1) {document.write('<link rel="stylesheet" href="/stylesheets/opera.css" type="text/css" media="screen"/>');};

function showPopup (current) {
	showShadow();
	document.getElementById(current).style.display = "block";
	if (document.getElementById("login_field")) document.getElementById("login_field").value = ""; 
	if (document.getElementById("password_field")) document.getElementById("password_field").value = "";
	if (document.getElementById("login_field")) document.getElementById("login_field").focus();
	return false;
}

function hidePopup (current) {
	document.getElementById(current).style.display = "none";
	hideShadow();
	return false;
}

function showShadow() {
	var shadow = document.getElementById("shadow");
	shadow.style.display = "block";
	document.body.className += " hideselects";
	var bodyHeight = document.body.clientHeight;
	var wrapHeight = document.getElementById("wrap").clientHeight;
	if (wrapHeight > bodyHeight) shadowHeight = wrapHeight;
	else shadowHeight = bodyHeight;
	shadow.style.height = shadowHeight + "px";
	return false;
}

function hideShadow() {
	var shadow = document.getElementById("shadow");
	shadow.style.display = "none";
	document.body.className = document.body.className.replace(" hideselects", "");
	return false;
}

function showReply (current) {
	document.getElementById(current).style.display = "block";
	//document.getElementById("reply_field").value = "";
	document.getElementById("reply_field").focus();
	return false;
}


var ie/*@cc_on=1@*/;
function tableHover() {
	if(ie) {
		var tables = document.getElementsByTagName('table');
		for (var i=0; i<tables.length; i++) {
			if (tables[i].className == "blogs") {
				var tds = tables[i].getElementsByTagName('td');
				for (var j=0; j<tds.length; j++) {
					tds[j].onmouseover = function() {this.className += " hover"};
					tds[j].onmouseout = function() {this.className = this.className.replace(" hover", "")};
				}
			}
		}
	}
}



function init() {
	tableHover();
}

window.onload = init;