Copy Code code as follows:
var paras= "Ajaxflag=getmarkerids";
var myajax=new ajax.request (
"Addinfohandler.ashx",
{method: ' Get ', parameters:paras,oncomplete:showgetmarkeridsresponse}
);
Because I have a switch database operation, the first time into the database A, the list is loaded correctly, click the node (AJAX) map to display a data, but click IE back and then into the database B of the TreeView, the list loaded correctly (load list is not Ajax), Click on the node map to display the data is still a data (Ajax), I set a breakpoint in the addinfohandler.ashx, found that the above operation time into a database breakpoint hit, and into the B database did not enter a breakpoint, but I am really strange, did not enter the page unexpectedly Ajax has returned data, and the same as the last time, should be the use of the caching mechanism. The last information on the Internet was changed as follows:
Copy Code code as follows:
var myajax=new ajax.request (
"Addinfohandler.ashx",
{method: ' Get ', requestheaders: [' Cache-control ', ' no-cache ', ' if-modified-since ', ' 0 '],parameters:paras,oncomplete: Showgetmarkeridsresponse}
);
The following can refer to previously published articles
Http://www.jb51.net/article/22074.htm
Introduction to Response.setheader parameters and usage
Detailed source reference: Http://www.jb51.net/article/16437.htm