使用javascript获取Url的参数
<script language=javascript>
//获取url的参数
function GetUrlParams()
{
//获取参数串
var args = new Object();
var search = location.search.substring(1);
if(search != '')
{
var params = search.split('&');
for(i = 0;i < params.length;i++)
{
var pos = params[i].indexOf('=');
var key = params[i].substring(0,pos);
var value = params[i].substring(pos+1);
args[key] = value;
}
}
return args;
}
var args = GetUrlParams();
alert(args['param']);
</script>