要说的是,返回的变量是字符串数组,不是字符串。例如:
var url = location.search.match(/&Location=[w]+/i); if(url.length == 0) return; var loc = url[0].replace('&Location=','');