I have a view with the following -
<img src= "@Url.Content(new Uri(image.Path).AbsoluteUri)" alt="@(new Uri(image.Path).AbsoluteUri)" />
image.Path is a string
It renders the below html
<img alt="file:///C:/Users/Tom/MyAppApp_Data/uploads/myImage.jpg" src="file:///C:/Users/Tom/MyAppApp_Data/uploads/myImage.jpg">
But the image is not displayed in the browser.
If I open FireBug and hover over the image element, the image will show in the FireBug window.
If I take the above html and place in a test.html file and open the file in a browser, the image is displayed.
However, if I hard code the above html into my view, it does NOT work!
UPDATE 1
If I save the page in Firefox, the image is downloaded and when I open the html file the image is displayed.
This is beginning to sound like an IIS Express problem.
UPDATE 2
If I look at the view in the Page Inspector the images show up as expected!
image.Pathis a string~?