Custom HTTP Handler for images

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-12 03:27:24

问题


I'm creating a custom image handler to handle all *.jpg requests. I would like to register it in IIS 7 & above by Add Manage Handler. I have two choices:

Create a separate ASP.Net web application project and create a class under App_Code folder which contains only handler code. In this way by adding handler to web.config I would be able to register handler into IIS.

OR

Create a class library project without entire ASP.Net structure. In this way I need to use IIS interface and manually register managed handler.

Question is which way is better? Can I avoid overhead of entire ASP.Net Framework by just creating class library project?

来源:https://stackoverflow.com/questions/19025514/custom-http-handler-for-images

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!