最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - window.showModalDialog and postback button - Stack Overflow

programmeradmin1浏览0评论

I have two pages A.aspx and B.aspx

Page A.aspx opens B.aspx as modal popup by javascript function window.showModalDialog("B.aspx");

Page B.aspx has two text boxes (Login, Password), <asp:Button> control and button click event in server code.

Problem is when I click on the submit button it opens me B.aspx page in new third window

How is it possible to not open new window on submit button. Thanks!

I have two pages A.aspx and B.aspx

Page A.aspx opens B.aspx as modal popup by javascript function window.showModalDialog("B.aspx");

Page B.aspx has two text boxes (Login, Password), <asp:Button> control and button click event in server code.

Problem is when I click on the submit button it opens me B.aspx page in new third window

How is it possible to not open new window on submit button. Thanks!

Share Improve this question asked Feb 2, 2011 at 11:28 ihorkoihorko 6,95526 gold badges80 silver badges123 bronze badges
Add a ment  | 

2 Answers 2

Reset to default 8

simply in the modal window put this to the <HEAD>

<BASE target="_self">

move B.aspx code to B.ascx (user control)

发布评论

评论列表(0)

  1. 暂无评论