<A href = "javascript: showModalDialog ('ansmsg. aspx? Id = <% # Eval ("gid") %> '); window. location. reload () ">
Reply </a>
A common page points to the link... passing the parameter ID in the past... and then adds window. location. reload ()
This window. location. reload () indicates that the parent page is refreshed after the mode form is closed.
Ansmsg. aspx is the mode form to be popped up ..
Add the following code on the ansmsg. aspx page:
protected void Page_Load(object sender, EventArgs e)
{
Response.Expires = 0; }
This indicates that the mode form page cache is disabled ..
If this is not done, the address bar ID will not change. The content will not change ..
For example, my function is as follows ..:
In this case .. if you do not add a forbidden page cache .. I need to reply message board information .. repeat the mode form opened by the "reply" link .. the content will not change .. even if the database has been updated...
If this page is closely displaying information, but there is no submit button... I want to do this already OK...
However, this mode form has a submit button, which means that I need to send data back ..
At this time, a problem occurs ....
After you click the submit button, the format will be displayed on the new page...
The meaning of the mode form is lost...
This is not very good... but how can we solve it?
The method is very simple ..
Add the following code to the source code of the page that appears as the mode form ..
<base target="_self" />
<body>