To convert relative image paths to absolute path there are many questions asked and answered in stackoverflow like this one:

MVC4 StyleBundle not resolving images

that suggest adding new CssRewriteUrlTransform() as below:

bundles.Add(new StyleBundle("~/Content/css/jquery-ui/bundle")
       .Include("~/Content/css/jquery-ui/*.css", new CssRewriteUrlTransform()));

and this actually have saved me before. but now that I deploy my website to an application (not root of a website) there is still a problem:

the application is:


but the image urls are like:


while it should be:


although the css link itself is correct and working.

Related posts

Recent Viewed