GetParam(name)

 function GetParam(name) {
            var match = new RegExp(name +  
                "=*([^&]+)*", "i").exec(location.search);   
            if (match == null)             
                match = new RegExp(name + "=(.+)", "i").exec(location.search);  
            if (match == null) return null;             
                match = match + "";           
            //**convert match to a string       
            result = match.split(",");          
            return decodeURIComponent(result[1]);     
        } 

 

posted @ 2014-07-08 09:17  microsoftzhcn  阅读(3035)  评论(0编辑  收藏  举报