Disable Image.ashx handler

Topics: Developer Forum, Project Management Forum, User Forum
Oct 29, 2008 at 12:14 PM
Hi, I have  a legacy site in which I want to incorporate N2.
How can I disable the Image handler for pages which are not derived from the ContentItem object?
I want to enable the handler only for the pages created with N2, else this breaks some javascript code.

Oct 29, 2008 at 2:43 PM
Fixed it, modified this:
if (!ImageControl.Height.IsEmpty || !ImageControl.Width.IsEmpty)
to this:
if ((!ImageControl.Height.IsEmpty || !ImageControl.Width.IsEmpty) && (N2.Context.CurrentPage != null))
in ImageAdapter class.

Hope this helps others too.