If I use routing with 2 query parameters, like this:
System.Web.Routing.RouteTable.Routes.MapPageRoute("HomeRoute", "home/{f1}/{f2}", "~/Home.aspx");
My image does not appear on my Home.aspx page:
<img src="~/img/img.jpg" /> or <img src="img/img.jpg" />
But it does appear when I access the http://localhost:3760/Website/Home.aspx
URL
I tried using Routing.Ignore with no luck. I look for a solution wich should work for an unlimited number of subfolders: "home/{f1}/{f2}/.../{fn}"
The problem is raised by ASP.NET routing module. The image will show if I type <img src="../../img.jpg" />
but this goes further to <img src="../../../img.jpg" />
if I have "home/{f1}/{f2}/{f3}" on the routing rule