+3  A: 

To be honest, I don't think its really something to worry about... "/Content" is going to make a pretty minimal contribution to your page size. If you still want to do it, here are some options:

Option 1, if you are running on your own server, is to check out the IIS URL Rewrite module: http://learn.iis.net/page.aspx/460/using-url-rewrite-module/

Option 2 is to use either RedirectResult, or ContentResult, to achieve the same effect in the MVC framework

First, map a "catchall" route under "Images/" to a controller action, like so

routes.MapRoute("ImageContent", 
                "Images/{*relativePath}", 
                 new { controller = "Content", action = "Image" })

Make sure it is above your standard "{controller}/{action}/{id}" route. Then, in ContentController (or wherever you decide to put it):

public ActionResult Image() {
    string imagePath = RouteData.Values["relativePath"]
    // imagePath now contains the relative path to the image!
    // i.e. http://mysite.com/Images/Foo/Bar/Baz.png => imagePath = "Foo/Bar/Baz.png"
    // Either Redirect, or load the file from Content/Images/{imagePath} and transmit it
}

I did a quick test, and it seemed to work. Let me know in the comments if you have any problems!

anurse
actually worrying about the extra number of bytes was my attempt at a joke. i just dont like to see <img src="../content/images/...">. it just doesnt feel right, but if thats the established convention then thats ok. your implementation looks nice and clean though. thanks
Simon_Weaver
+2  A: 

It's usually better to put images under a different sub domain. The reason for this is browsers limit the number of connections per URL. So if you use http://static.mysiste.com now the browser can open more concurrent connections due to it being in a different URL.

Chad Moran
i actually jsut learned about that yesterday. i couldnt believe IE STILL only downloads 2 files at a time. i knew it limited - but TWO files!!
Simon_Weaver
i'll probably have to write an Html helper to write out an image tag that is confuguration driven to determine the root for my images. that would have the added bonus of getting to stop adding 'content' to all my images. Html.Image("images/backgrounds/1.jpg") which would go to config for base path
Simon_Weaver