var changedEmail = false;
var changedPasswd = false;
function updateLoginForm(inputEle)
{
	if (inputEle.name == "email" && !changedEmail)
	{
		inputEle.value = "";
		changedEmail = true;
	}
	else if (inputEle.name == "password" & !changedPasswd)
	{
		inputEle.type = "password";
		changedPasswd = true;
		var b = changedEmail;
		changedEmail = true;
		document.getElementById('loginForm').email.focus();
		inputEle.focus();
		changedEmail = b;
		inputEle.value = "";
	}
}

function openSecurityCode()
	{ window.open("/cc_security.php", "security", "height=650,width=680,status=yes,toolbar=yes,menubar=no,location=no"); }

function verifyRequired()
{
	if (document.icpsignup["fields_email"].value == "")
	{
		document.icpsignup["fields_email"].focus();
		alert("The Email field is required.");
		return false;
	}
	return true;
}
function openDetailStock(symbol)
{ 
	var w = 520;
	var h = 260;
	var winl = (screen.width - w) / 2;
	var wint = (screen.height - h) / 2;
	var winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1';
	// win = window.open("http://app.quotemedia.com/quotetools/clientForward?/quotetools/popups/quote.jsp?&cp=on&symbol=MSFT&webmasterId=90649&targetURL=" + escape('http://app.quotemedia.com/quotetools/popups/quote.jsp') + "&cp=on&symbol=" + symbol, "DetailedQuote", winprops);
	win = window.open("http://app.quotemedia.com/quotetools/popups/quote.jsp?&cp=on&webmasterId=90649&symbol=" + escape(symbol), "DetailedQuote", winprops);

	if (parseInt(navigator.appVersion) >= 4)
		win.focus();
}
function openChatClient()
{
	newwindow = window.open('/members/cclient.php','marketschat','width=634,height=476,resizable=1');
	if (newwindow.focus) { newwindow.focus() }
	
	return false;
}

