var URLParams = new Array();
var aParams = document.location.search.substr(1).split('&');
for (i=0; i < aParams.length ; i++){
var aParam = aParams[i].split('=');
URLParams[aParam[0]] = aParam[1];
}
//取得传过来的name参数
name=URLParams["name"];
document.write(name);
var aParams = document.location.search.substr(1).split('&');
for (i=0; i < aParams.length ; i++){
var aParam = aParams[i].split('=');
URLParams[aParam[0]] = aParam[1];
}
//取得传过来的name参数
name=URLParams["name"];
document.write(name);