Question

I have a generic handler Image.ashx that crops/resizes images on the fly by reading information from the querystring like Image.ashx?filename=foo.jpg&maxwidth=200&maxheight=300.

Is there a way that I can change the extension of this handler to .jpg? (it always returns jpgs) I'd rather the calls look like this: Image.JPG?filename=foo.jpg&maxwidth=200&maxheight=300?

Was it helpful?

Solution

Yes, you can use the routing infrastructure to point image.jpg to image.ashx

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top