Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2008

ASP.NET Zip Entry Handler

Jake Morgan recently submitted an article to Codeproject.com detailing how to deploy zip files to a web application and serve uncompressed files directly out of the zip file. We use this technique on Elsitech.com for our Developer Labs section. The full Codeproject.com article contains implementation discussion and the sample code needed.

Screenshot of Zip Entry Hanlder

From the article:

The ZipEntryHandler enumerates and serves files out of static zip files deployed in your web space. The handler is implemented as a simple ASP.NET IHttpHandler deployed with a code file in the App_Code directory on your website and configured with a line in the web.config file. The handler is very useful for several purposes:

  • Serving otherwise prohibited files - Code files with extensions that have special meaning to the web application ("cs", "vb", "aspx") can be served statically.
  • Storage Space - Very compressible content often consumes large amounts of web space. This handler allows content to be stored compressed without special access to the file system on a web server.
  • Maintainability - Often a zip file and the contents of the zip file should both be downloadable and browsable. This pattern allows solely the zip file to be deployed without having to synchronize other downloads.

Categories: Development
Posted by Mike Richards on Monday, May 19, 2008 9:06 AM
Permalink | Comments (0) | Post RSSRSS comment feed

Related posts

Add comment


 

  Country flag

[b][/b] - [i][/i] - [u][/u]- [quote][/quote]



Live preview

Tuesday, October 07, 2008 9:15 AM