I have a custom httpHandler in my ASP.NET MVC application that is to be executed whenever an image is requested. If I have a css definition like this:
div#cssSwitch
{
background-image: url('/Content/themes/base/images/a.png');
}
during load of the page the handler is executed. However, I also have this piece of css
div#cssSwitch:hover
{
background-image: url('/Content/themes/base/images/b.png');
}
but the handler is never executed for this image. Not during load of the page, not after hovering above the element. Why?
EDIT
My handler is empty so far. I am debugging it locally with breakpoint for the application to break when the handler is executed.
So far it seems the image on :hover
has been cached. When cache is deleted, it works as expected. However, I would prefer a way to deny caching of the image. Is there something?
Regards, Trim.