Compartir a través de


Popup dialog opens new window on postback

Popup dialog opens new window on postback

hi all,

many times we use  popup dialogues opened with window.showmodaldialog(“samp.aspx“). but if there is postback happening on this window , you would see that this aspx opens in a new window.

i have a solution.. which is

add this to the head of your aspx
<head>
<title>Text</title>
 <BASE target="_self">
.
.
</Head>

after adding you need to kill worker process rebuild and restart iis before you test this.

bcos iis always serves the cached version of the aspx as a popup.