开发者

Master Site links not working under iis6

ASP开发者_如何学编程 MVC 1.0 being hosted on IIS 6.

I set up the wildcard filtering already.

The path ../../site.css and the like in the master page (shared/site.master) do not work when posted to the IIS 6 staging site. I ended up hard coding them to the site.

Works fine on the ASP .Net VS dev server


You should use Url.Content for this, e.g.:

<link href="<%= Url.Content("~/Content/style/Site_Master.css") %>" rel="stylesheet"
    type="text/css" />

The ~ means "the site root", whereever that happens to be.


Could you check the IIS log file to see if/which request is being made?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜