jiaojiao7 4 年之前
父節點
當前提交
38294b0441
共有 1 個文件被更改,包括 12 次插入0 次删除
  1. 12 0
      static/templates/moneyRecharge.html

+ 12 - 0
static/templates/moneyRecharge.html

@@ -16,6 +16,18 @@
     </body>
     </body>
     </html>
     </html>
     <script>
     <script>
+        var appid = getParam("appId");
+        // 获取上个页面传来的参数
+        function getParam(name) {
+            var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
+            var r = window.location.search.substr(1).match(reg); //获取url中"?"符后的字符串并正则匹配
+            var context = "";
+            if (r != null)
+                context = r[2];
+            reg = null;
+            r = null;
+            return context == null || context == "" || context == "undefined" ? "" : context;
+        }
         function submit(param, rType, url, hearders) {
         function submit(param, rType, url, hearders) {
             $.ajax({
             $.ajax({
                 url: url,
                 url: url,