How do I route images through ASP.NET routing?

后端 未结 5 1253
一生所求
一生所求 2021-02-09 07:31

I\'d like to create a dynamic thumbnail resizer so that you can use the following URL to get a resized image:

http://server/images/image.jpg?width=320&height         


        
5条回答
  •  执笔经年
    2021-02-09 07:47

    Why not just use an action to do this? A controller's action can stream back an image. Otherwise, the typical way, say with ASPX, is that a handler or handler factory listens for the file extension and processes it accordingly. Or use URL rewriting to rewrite the URL in the request.

提交回复
热议问题