问题描述
我们有虚拟目录下的Web应用程序部署。现在,我们想将它移动到它自己的网站的SSL配置。
we had a web application deployed under virtual directory. Now we want to move it to it's own website for SSL configuration.
不过,也有许多 HttpContext.Current.Request.ApplicationPath
为预期的应用程序不工作的结果。
However, there are lots of HttpContext.Current.Request.ApplicationPath
as a result the application is not working as expected.
任何人都可以请帮我有什么替代 HttpContext.Current.Request.ApplicationPath
来找到网站的根?
Could anyone please help me with what's the alternative to HttpContext.Current.Request.ApplicationPath
to find root of website?
在虚拟目录设置它给了正确的路径图像,而在网站上它只是给
On virtual directory setup it gives correct path to images whereas on website it just gives
这是不好的。
感谢堆。
推荐答案
您可以试试这个
HttpRuntime.AppDomainAppPath
和替代
HttpContext.Current.Request.PhysicalApplicationPath
这篇关于HttpContext.Current.Request.ApplicationPath的网站的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!