Coldfusion Error and IIS7.5 Error Pages

前端 未结 2 1750
逝去的感伤
逝去的感伤 2020-12-29 12:32

In order to allows ColdFusion showing its errors instead of just server error (code 500), I have added to web.config according to some findings in this site.

The pr

2条回答
  •  南方客
    南方客 (楼主)
    2020-12-29 13:12

    Keeping the passthrough in place, you could use a rewrite to handle the blank page:

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /404.cfm [NC,L,NS]
    

    The rewrite basically means - if file and directory do not exist, redirect to "404.cfm. Also include a 404 cfheader on the 404.cfm page.

提交回复
热议问题