[英]Broken link after deploying asp.net web application IIS7
I have my web_app that i want to deploy under the existing domain.it/我有我想在现有 domain.it/ 下部署的 web_app
The problem is that all urls in the web_app are absolute, so all the links are broken.问题是 web_app 中的所有 url 都是绝对的,所以所有的链接都被破坏了。
How i can say, is it possible, for iis to change the root level of the web_app?我怎么说,iis 是否可以更改 web_app 的根级别? I can't deploy web_app folder under root.
我无法在根目录下部署 web_app 文件夹。
Thanks!!谢谢!!
If you use path in such a way, then you don't need to care where your application will be deployed.如果您以这种方式使用路径,那么您不需要关心您的应用程序将部署在哪里。 look below some example....
看下面的一些例子....
<img alt="" runat="server" src="~/Images/abc.jpg" />
<asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/About.aspx">HyperLink</asp:HyperLink>
~
Will map to Application Root Directory ~
将 map 到应用程序根目录
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.