方法二:
方法三:
functiongetUrlPara(paraName){
varsUrl=location.href;
varsReg="(?:?|&){1}"+paraName+"=([^&]*)"
varre=newRegExp(sReg,"gi");
re.exec(sUrl);
returnRegExp.$1;
}
//应用实例:test_para.html?a=11&b=22&c=33
alert(getUrlPara("a"));
alert(getUrlPara("b"));