if (window.attachEvent && !window.opera) {
	window.attachEvent("onload", initInputs);
}

function initInputs()
{
	var inputs = document.getElementsByTagName("input");
	for (var i=0; i<inputs.length; i++)
	{
		if (inputs[i].type == "text")
		{
			inputs[i].onfocus = function ()
			{
					if (this.className.indexOf("focus") == -1)
					{
						this.className += " focus";
					}
			}
			inputs[i].onblur = function ()
			{
					this.className = this.className.replace("focus", "");
			}
		}
	}
}