當我在Visual Studio中運行我的webapp時,出現錯誤頁面的原因是什麼? URL爲http://localhost:5000/ HTTP錯誤403.14 - 禁止 Web服務器配置爲不列出此目錄的內容。運行webapp時出現「HTTP Error 403.14 - Forbidden」錯誤
0
A
回答
0
原因:http://localhost:5000指的是網絡服務器的根目錄。因此,對於上述請求,它會嘗試讀取服務器的根文件夾。但是,默認情況下IIS(快速)不允許您查看文件系統。因此它顯示以上錯誤。
很可能你不需要訪問服務器的根目錄,而是可能需要訪問你的webapp(例如:http://localhost:5000/myapp)。
但是,如果你知道自己在做什麼,那麼你可以啓用IIS使用以下配置在應用程序的Web.config顯示根目錄(文件系統)
Important: Below config should not be activated in a production or any publicly reachable environment which is obviously a high critical security issue.
<system.webServer>
<directoryBrowse enabled="true" />
<modules runAllManagedModulesForAllRequests="true"></modules>
</system.webServer>
0
有兩件事通常是當我得到這個錯誤時的問題:
第一:我從來沒有定義過一個標準的文檔,並在某些時候改變它 - 因此,在這種情況下IIS自動定義的標準文檔不存在
第二:我沒有啓用索引搜索
您可能想試試這個。您可以直接在IIS設置中更改這些設置。
相關問題
- 1. 爲什麼在重定向URL後出現「HTTP Error 403.14 - Forbidden」錯誤?
- 2. http error 403.14-禁止
- 3. HTTP錯誤403.14 - 訪問網站時出現禁止錯誤
- 4. HTTP錯誤403.14
- 5. 運行時出現錯誤
- 6. 獲取HTTP 403.14錯誤
- 7. HTTP錯誤403.14 ASP配置
- 8. 試圖運行cylone.js時出現錯誤「Error opening com7:File not found」
- 9. HTTP錯誤403.14 - 呼叫控制器
- 10. Roundcube Server Error Forbidden
- 11. 運行manova時出現SPSS錯誤
- 12. HTTP錯誤403.14 - 禁止。 Asp.NET MVC
- 13. MVC 5 HTTP錯誤403.14 - 禁止
- 14. 運行Caffe時出現兩個錯誤
- 15. Swagger給我HTTP錯誤403.14 - 禁止
- 16. 錯誤403.14 IIS7上
- 17. 運行anova時出現錯誤消息
- 18. 運行時出現錯誤:java.lang.ClassNotFoundException:org.springframework.web.context.ContextLoaderListener
- 19. 運行php腳本時出現http 500錯誤
- 20. 運行jmeter.bat時出現Jmeter錯誤
- 21. 運行grunt-contrib-imagemin時出現錯誤
- 22. IIS - http運行時錯誤
- 23. 訪問ADF書籤URL時出現「Error 403 - Forbidden」
- 24. NSIS從Jenkins運行時出錯Error
- 25. Cordova:npm運行時出錯error build_android
- 26. 運行make install時出現RVM錯誤。安裝power_assert gem時出現錯誤
- 27. HTTP錯誤403.14安裝VS 2015之後
- 28. ASP.NET和IIS 7.5 - HTTP錯誤403.14 - 禁止
- 29. 如何解決HTTP錯誤403.14 - 禁止
- 30. HTTP錯誤403.14在ASP.NET MVC2應用