1, the ShowModalDialog function opens the window when the page is submitted to reopen the new page solution
In
2, return value window.returnvalue problem
If both the parent form and the subform are HTML with JS or jquery directly in the pop-up page window.returnvalue the corresponding value of the parent form is received;
If both the parent form and the subform are. aspx pop-up pages that need to submit data to the server side and refresh the page with a new page reopen problem with 1 resolution, there is a need to rely on the background to return the Window.returnvalue value problem, which requires us to return the following in the background:
Response.Write ("<script type=\" text/javascript\ ">window.close (); window.returnvalue= '" + URL +
"'; if (window.opener) {window.opener.returnvalue= '" + URL + "';} </script> ");
URL is the value we need to return, the parent window is as follows
var url = ". /videoupload/newuploadbigfile.aspx? Type= "+ t +" &etc= "+ New Date (). GetTime ();
obj = document.getElementById (o);
var f = ShowModalDialog (URL, "File Upload", "Dialogwidth=450px;dialogheight=150px;status:no;scroll=no;help:no");
if (f) {
obj.value = f;
}
Receive, where if (window.opener) {window.opener.returnvalue= ' "+ URL +" ';}, This is because Google Chrome does not support setting up returnvalue directly on the ShowModalDialog pop-up form, as an alternative to setting up window.opener.returnValue in a pop-up window to resolve compatibility issues.
ShowModalDialog parent page, pop-up question, and return value question note