IE6 Dropdownlist使用Ajax Modalpopupextender消失

编程入门 行业动态 更新时间:2024-10-18 06:11:45
本文介绍了IE6 Dropdownlist使用Ajax Modalpopupextender消失的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

你好, 我在下面插入了简单的示例代码,如果您使用IE 6运行它,则在显示Ajax modalpopupextender时,将看到dropdownlist控件消失. 有人可以告诉我如何修改此代码,以使dropdownlist控件不会消失.感谢您为解决此问题所提供的帮助. 谢谢你!

Hello, I''ve inserted simple example code below that if you run it using IE 6 you will see the dropdownlist control disappears when you display a Ajax modalpopupextender. Can someone show me how to modify this code so that the dropdownlist control does NOT disappear. I appreciate any help to solve this problem. Thank You!

<![CDATA[<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApp.WebForm1" %>]]> <![CDATA[<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>]]> <html> <head runat="server"> </head> <body> <form id="form1" runat="server"> <asp:scriptmanager id="ScriptManager1" runat="server" xmlns:asp="#unknown"> </asp:scriptmanager> <div> <table> <tr> <td>State:</td> <td> <asp:dropdownlist id="ddlState" runat="server" autopostback="true" xmlns:asp="#unknown"> <asp:listitem>WI</asp:listitem> <asp:listitem>NY</asp:listitem> <asp:listitem>GA</asp:listitem> </asp:dropdownlist> </td> </tr> <tr> <td> </td> </tr> <tr> <td></td> <td> <asp:button runat="server" text="Try It Using IE6" id="btnTryIt" onclick="btnTryIt_Click" xmlns:asp="#unknown" /> </td> </tr> </table> </div> <asp:button id="btntar" runat="server" style="display: none" xmlns:asp="#unknown" /> <cc1:modalpopupextender id="mpePanel" runat="server" targetcontrolid="btntar" behaviorid="ClosePanel" xmlns:cc1="#unknown"> PopupControlID="pnlTest"&gt; </cc1:modalpopupextender> <asp:panel id="pnlTest" runat="server" backcolor="Brown" width="300px" height="250px" enableviewstate="false" xmlns:asp="#unknown"> <div style="color: White;">I created this simple example of a dropdown control (that disappears) using an AJAX ModalPopupExtender. Can someone modify this code where the state DROPDOWN CONTROL will not disapper in IE6 while this modalpopup window is displayed? I would greatly appreciate it!</div> <div align="center" style="padding-top: 20px;"> <input type="button" runat="server" id="btnClose" onclick="$find('ClosePanel').hide();" value="Close" /> </div> </asp:panel> </form> </body> </html>

using System; using System.Web; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; namespace WebApp { public partial class WebForm1 : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } protected void btnTryIt_Click(object sender, EventArgs e) { mpePanel.Show(); } } }

推荐答案

find('ClosePanel').hide();" 值 =" 关闭" / > < /div > < /asp:panel > < /form > < /body > < /html >

using System; using System.Web; using System.Web.UI; using System.Web.UI.HtmlControls; using System.Web.UI.WebControls; namespace WebApp { public partial class WebForm1 : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } protected void btnTryIt_Click(object sender, EventArgs e) { mpePanel.Show(); } } }

下拉列表组件被显式隐藏,因为在IE6中,否则它会位于modalpopup之上.使用div元素作为弹出窗口的大多数优秀javascript弹出库都可以做到这一点.查看下面的链接(虽然该链接通常在网站上不可用),然后在页面底部查看示例.在此之上,您会看到一个使用IE6时隐藏的下拉菜单. www.javascripttoolbox/lib/popup/example.php [ ^ ] 通常,下拉菜单将在关闭弹出窗口后再次显示. 祝你好运! The dropdown component is explicitly hidden because in IE6 this would otherwise be above the modalpopup. Most good javascript popup libraries that use div element as popup do this. Look at the link below (that is not normally available on the site though) and view the example on the bottom of the page. Above that you see a dropdown that is hidden when using IE6. www.javascripttoolbox/lib/popup/example.php[^] Normally the dropdown will be shown again after the popup is closed. Good luck!

停止! 对IE6不执行任何操作,拒绝对其进行操作,破坏所有需要它的产品! 它不受支持,存在重大缺陷,并且正在全球范围内逐步淘汰. 如果人们仍然使用它并且可以找到功能,那就是他们的监视点. STOP! Do nothing for IE6, refuse to work on it, sabotage every product that requires it! It is unsupported, has major flaws and is being phased out across the world. If people still use it and can find functionality, that is their lookout.

更多推荐

IE6 Dropdownlist使用Ajax Modalpopupextender消失

本文发布于:2023-11-25 01:52:51,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1627830.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:Dropdownlist   Modalpopupextender   Ajax

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!