// JavaScript Document
window.onload = function()
{
	
	// this will tell the php script if javascript is turned on or not...
	if( window.opener )
    {
	    document.getElementById( "javascriptTest" ).value = "on";
    }
	
	var errorTest;
	errorTest = document.getElementById( "errorsFound" );
	if( errorTest.value == 'no' )
	{
		window.opener.document.location.href='/plans/compare.html?stateSelector=' + 
        document.getElementById( "stateSelector" ).options[document.getElementById( "stateSelector" ).selectedIndex].value;
		window.parent.close();
		return false;
	}
}
