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();

      

  • 相关阅读:
    时间选择器和日期选择器
    paip.c++ qt 项目工程互相引用的方法
    leetcode_question_85 Largest Rectangle in Histogram
    在VirtualBox虚拟机上采集Fedora15系统
    Oracle
    VC6.0调试大全
    oracle中的exists 和not exists 用法详解
    vi常用命令
    【虚拟化实战】容灾设计之四VPLEX
    CentOS6.3 安装配置 ant
  • 原文地址:https://www.cnblogs.com/lengv10/p/3671336.html
Copyright © 2011-2022 走看看