使用window.showModalDialog弹出aspx页面,如果页面中使用了服务端控件,如:<asp:button class="ButtonCss" id="btn_Search" runat="server" Text="搜索">;当点击按钮时,会向服务器回传页面并刷新页面,这时候,页面会在一个新的窗口中打开。
解决办法 :
是showModalDialog显示的那个aspx面中:在<head></head>里加入<base target="_self">,即可
使用window.showModalDialog弹出aspx页面,如果页面中使用了服务端控件,如:<asp:button class="ButtonCss" id="btn_Search" runat="server" Text="搜索">;当点击按钮时,会向服务器回传页面并刷新页面,这时候,页面会在一个新的窗口中打开。
解决办法 :
是showModalDialog显示的那个aspx面中:在<head></head>里加入<base target="_self">,即可