﻿function searchUrl(argName,argValue)
{
	/*
	argValue = escape(argValue);
	var hrefstr = window.location.href;
	
	hrefstr = hrefstr.replace("#","");
	
	var pos = hrefstr.indexOf("?");
	
	if(pos==-1)
	{
		hrefstr += "?"+argName+"="+argValue;
		
	}
	else
	{
		var paramValue = getparastr(argName);
		if(paramValue ==null)
		{
			hrefstr += "&"+argName+"="+argValue;
		}
		else
		{
			
			hrefstr = hrefstr.replace(argName+"="+paramValue, argName+"="+argValue);
		
		}
	}
	*/
	var url = "http://www.songlila.com/CommodityList.aspx?"+argName+"="+argValue;
	window.location.href = url;
	//return;
}

function searchPricUrl(argName, argValue, argName1, argValue1)
{
	argValue = escape(argValue);
	var hrefstr = window.location.href;
	
	hrefstr = hrefstr.replace("#","");
	
	var pos = hrefstr.indexOf("?");
	
	if(pos==-1)
	{
		hrefstr += "?"+argName+"="+argValue+"&"+argName1+"="+argValue1;
	}
	else
	{
		var paramValue = getparastr(argName);
		if(paramValue ==null)
		{
			hrefstr += "&"+argName+"="+argValue;
		}
		else
		{
			hrefstr = hrefstr.replace(argName+"="+paramValue, argName+"="+argValue);
		}
		
		var paramValue1 = getparastr(argName1);
		if(paramValue1 ==null)
		{
			hrefstr += "&"+argName1+"="+argValue1;
		}
		else
		{
			hrefstr = hrefstr.replace(argName1+"="+paramValue1, argName1+"="+argValue1);
		}
	}
	window.location.href = hrefstr;
}
/*
*其他页面调用的
*/
function searchUrlByOther(argName,argValue)
{
	argValue = escape(argValue);
	var hrefstr = "http://www.songlila.com/CommodityList.aspx";
	hrefstr += "?flg=2&tagid="+argName+"&tagname="+argValue;
	window.location.href = hrefstr;
}
function searchPricUrlByOther(argName, argValue, argName1, argValue1)
{
	argValue = escape(argValue);
	var hrefstr = "http://www.songlila.com/CommodityList.aspx";
	hrefstr = hrefstr.replace("#","");
	hrefstr += "?"+argName+"="+argValue+"&"+argName1+"="+argValue1;
	window.location.href = hrefstr;
}

