function getQueryStringByName(name) {
var index = window.location.href.indexOf("#");
if (index != -1) {
return getquery(window.location.href)[name];
}
}
function getquery(href) {
var index = href.indexOf("#");
if (index != -1) {
var query = href.substring(index + 1);
var arr = query.split("&");
var result = {};
for (var i = 0; i < arr.length; i++) {
var item = arr[i].split("=");
result[item[0]] = item[1];
}
return result;
}
return null;
}
var index = window.location.href.indexOf("#");
if (index != -1) {
return getquery(window.location.href)[name];
}
}
function getquery(href) {
var index = href.indexOf("#");
if (index != -1) {
var query = href.substring(index + 1);
var arr = query.split("&");
var result = {};
for (var i = 0; i < arr.length; i++) {
var item = arr[i].split("=");
result[item[0]] = item[1];
}
return result;
}
return null;
}