Explorar o código

前端获取链接参数解码时使用decodeURI替换unescape

sunyj %!s(int64=9) %!d(string=hai) anos
pai
achega
cb0fbb3ab4
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/main/webapp/resources/js/preview/app.js

+ 1 - 1
src/main/webapp/resources/js/preview/app.js

@@ -47,7 +47,7 @@ var getParameter = function(key) {
 	var reg = new RegExp("(^|&)" + key + "=([^&]*)(&|$)");
 	var reg = new RegExp("(^|&)" + key + "=([^&]*)(&|$)");
 	var r = window.location.search.substr(1).match(reg);
 	var r = window.location.search.substr(1).match(reg);
 	if (r != null)
 	if (r != null)
-		return unescape(r[2]);
+		return decodeURI(r[2]);
 	return null;
 	return null;
 };
 };