Posted on 2007-11-06 08:39
itspy 阅读(253)
评论(0) 编辑 收藏
function gup( name ){
name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]");
var regexS = "[\\?&]"+name+"=([^]*)";
var regex = new RegExp( regexS );
var results = regex.exec( window.location.href );
if( results == null ) return ""; else return results[1];
}
var frank_param = gup( 'frank' );
alert(frank_param);