|
|
|
|
|||||||||||||||||
Click here to return to my article index
Application Cache ViewerASP.NET and the .NET Framework automagically cache pages as they are accessed by site visitors. This obviously speeds up the response time of your website. In addition to ASP.NET's ability to cache pages for us, we are able to store selectively cache items for use in our applications. Ever wonder what ASP.NET is caching at any given time? I put together a very simple cache viewer that will display items stored in the local applications cache. The way the code is currently written, the cache viewer does not show us the pages that are currently being cached by ASP.NET or the ASP.NET worker processes that are caching various items. However, the code is included in this article so you are free to grab the code and comment out the If..Then logic that prevents the System and ISAPI cache from showing. Remember that this example is running on my application here on AspAlliance.com and other users may be using the online version of this application. So, you may experience inconsistent behaviour online. I recommend you grab the code and run it on your machine.
First, let's make sure we have added some items to the application cache. We can do that with this simple little script I put together.
Once you have run the addcache.aspx page, you can run the cache menu application to view the contents of our application cache. If you want to see every item stored in your application cache then comment out the If..Then logic in cachemenu.aspx. There are comments in the downloadable source that tell where you can make this change. Click here to download the code for both pages (addcache.aspx and cachemenu.aspx) | |||||||||||||||||||
| Copyright © 2000-2003 ASPAlliance.com Page Rendered at
1/8/2009 1:04:05 PM |
|||||||||||||||||||