The personal Blog of Chris Dempsey

Chris is a web developer working freelance in Ayr nr Glasgow, Scotland. Other business interests include Underground Grapics, a company that manufactures vinyl decals for modified cars.

Thursday 15 October 2009

Setting Dynamic File Type as 404 Error Page in IIS 6

When setting a Custom Error page in IIS 6 you need to watch the drop down option for File or URL. Setting as File means IIS returns the page as markup so if using a dynamic file type such as PHP or ASP this setting returns your dynamic page as if it was a plain HTML page.

To ensure the dynamic 404 error page runs set the drop down to URL which makes IIS to send a redirect to the client so the client requests the Error Page which ensures IIS runs the dynamic page before sending the output to the client.