0
我已經編寫了一個httphandler來通過特定文件夾的URL攔截pdf文件請求,並將用戶重定向到登錄頁面。如果用戶通過身份驗證,則可以下載該文件。我的web.config中有攔截httphandler攔截IIS 6.0中的所有請求
<httpHandlers>
<add verb="*" path="/calderdale/*.pdf"
type="NES.HiLo.Security.CalderDaleAuthenticationHandler, NES.HiLo.Security" />
</httpHandlers>
我的web服務器是IIS 6.0中的下列項,我已經添加了應用程序擴展名映射具有可執行「C:\WINDOWS\microsoft.net\Framework\v2.0.50727\aspnet_isapi.dll
」和Exntension .pdf
和動詞爲「All verbs
」
所有除非發出公共pdf文檔的請求(不存在於指定目錄即calderdale中),則發生錯誤
「沒有收到數據.....」
任何想法我們如何才能截取pdf文件請求只是從指定的文件夾。
也許這會幫助嗎? [從自定義處理程序調用默認的asp.net HttpHandler](http://stackoverflow.com/questions/9930880/call-the-default-asp-net-httphandler-from-a-custom-handler) – jadarnel27 2013-05-08 19:26:04