zoukankan      html  css  js  c++  java
  • 页面传值出现乱码问题 window.showModalDialog()

    UI界面 encodeURI();

    var Setsup_no = $("#sup_no").val();

    wname = window.showModalDialog('../YZM_List/YZMPurchase_SList.aspx?Setsup_no=' +  encodeURI(Setsup_no) , '', 'dialogWidth:1024px;DialogHeight=678px;status:no;help:no;resizable:no;');

    接收页面后台Server.UrlDecode();

    sup_no.Value = Server.UrlDecode(HttpContext.Current.Request["Setsup_no"].ToString());

    sup_no.Value = Server.UrlDecode(Request.QueryString["Setsup_no"].ToString());

    主要函数

    encodeURI(string a);

    Server.UrlDecode(string b);

    方法一:

    UI界面 encodeURI();主界面
    
    var Setsup_no = $("#sup_no").val();
    
    wname = window.showModalDialog('../YZM_List/YZMPurchase_SList.aspx?Setsup_no=' +  encodeURI(Setsup_no) , '', 'dialogWidth:1024px;DialogHeight=678px;status:no;help:no;resizable:no;');
    
     
    
    接收页面后台Server.UrlDecode();从界面
    
    sup_no.Value = Server.UrlDecode(HttpContext.Current.Request["Setsup_no"].ToString());
    
    sup_no.Value = Server.UrlDecode(Request.QueryString["Setsup_no"].ToString());
    
     
    
    主要函数
    
    encodeURI(string a);
    
    Server.UrlDecode(string b);
    

      

    方法二:

    //页面传值;主界面
    
    wname = window.showModalDialog('../YZM_List/YZMPro_Analysis_SList.aspx?cust_no_id=' + escape(cust_no_id) , '', 'dialogWidth:1024px;DialogHeight=678px;status:no;help:no;resizable:no;');
    
    
    //后台获取;从界面
    
    Request.QueryString["cust_no_id"].ToString();


    主要函数
    escape();

      

  • 相关阅读:
    Echarts之美国新冠疫情地图制作
    前端三件套--CSS(pink老师课程笔记)
    数据预处理与转存(Hive--Mysql)
    HDFS的命令行使用
    hdfs的写入过程和读取过程
    树(一)树的基本知识
    指针中容易混淆的概念
    顺序查找、单链表查找、折半查找
    JAVA之I/O流
    SpringBoot-自定义spring-boot-starter
  • 原文地址:https://www.cnblogs.com/lengv10/p/3671336.html
Copyright © 2011-2022 走看看