// JavaScript Document
function checkForEnter(e, url)
{
	var charCode;
    if(e && e.which)
	{
		charCode = e.which;
	}
	else
	{
		charCode = e.keyCode;
	}

	//Check for the iPhone as it will thrown a w.which code of 10 when return is hit.
	/*if(navigator.platform == 'iPhone' && charCode == 10)
    {
		charCode = 13;
	}
	*/

	if(charCode == 13 || charCode == 10)
	{		
		var search = (document.getElementById("search").value);
		if(search.length > 0)
		{
		var path = url+'&keyword='+search;
		window.location = path;
		}	
		else
		{
			window.location = url;
		}
	}
}