zoukankan      html  css  js  c++  java
  • js中获取url参数

    function GridRowOnDblClick(strFile, pkValue, rowIndex) {   

           var myJSON = {

                value1: '',

                value2: '',

                load: function () {

                },

                serialize: function () {

                    var json = "";

                    for (var key in this) {

                        if (typeof this[key] != 'function') {

                            json += (json != "" ? "," : "") + key + ":'" + this[key] + "'";

                        }

                    }

                    json = '{' + json + '}';

                    return json;

                }

            }//end of myJSOON

          

          var obj = getUrlArgs();  //JS获取URL参数 

            if (typeof(myJSON) != 'undefined') {

                  myJSON.value1 = obj.CS;// URL参数

                  myJSON.value2 = pkValue;

           }

            $.ajax({

            type: "POST",

            contentType: "application/json",

            url: "/SlnWLPZ/KCWLPZ.aspx/GetCKWish",    

                  data:myJSON.serialize(),

            dataType: 'json',

            success: function (result) {

                var json = eval(result.d);

                if (json == "1") {

                  var r=rowIndex*1+1;

                  var grid = document.all.grdTest;  

                  var selectedRow = grid.rows[r];   

                  selectedRow.style.backgroundColor = '#76EE00';          

                }

                if (json == "0") {

                    alert('配置出错');

                }

                return false;

            } //success: function(result)

        }); //$.ajax

        return false;

    }

  • 相关阅读:
    android 选择图片或拍照时旋转了90度问题
    拍照选择图片(Activity底部弹出)
    Dialog 自定义使用1
    Dialog 基本使用
    秒杀主流应用的二维码扫描
    gen already exists but is not a source folder. Convert to a source folder or rename it.
    gen already exists but is not a source folder. Convert to a source folder or rename it.
    Unable to execute dex: Multiple dex files define
    xxxx is not translated in zh-rCN, zh-rTW
    Android Application 对象介绍
  • 原文地址:https://www.cnblogs.com/nuaaydh/p/4313298.html
Copyright © 2011-2022 走看看