In asp.net MVC I was loading blobed images from my db this way. It was displaying correctly on all browsers.
在asp.net MVC中,我以这种方式从我的数据库中加载blob图像。它在所有浏览器上都能正确显示。
using the following
使用以下内容
<div class="blogImage">
<a href="~/WaiGuoAtHome/ImageHtml/@Model.Id">
<img class="img-responsive homePhoto100" src="data:image;base64, @Convert.ToBase64String(Model.Image)" title="@Model.Caption" />
</a>
</div>
Navigate to the following page in firefox, IE and Chrome. Same code but on Chrome the image doesn't display. http://jacksonjhayes.azurewebsites.net/WaiGuoAtHome/ImageHtml/3646
导航到firefox,IE和Chrome中的以下页面。相同的代码但在Chrome上无法显示图片。 http://jacksonjhayes.azurewebsites.net/WaiGuoAtHome/ImageHtml/3646
I don't think this is a size issue, the image on that page is very big, but I display smaller images elsewhere that are much smaller.
我不认为这是一个尺寸问题,该页面上的图像非常大,但我在其他地方显示的图像要小得多。
1 个解决方案
#1
0
@onetrickpony your idea did the trick. Thanks! To bad I can't just use whatever image type I want any more but that makes sense, and I think all my images are jpeg anyway.
@onetrickpony你的想法成功了。谢谢!为了糟糕,我不能只使用我想要的任何图像类型,但这是有道理的,我认为我的所有图像都是jpeg。
#1
0
@onetrickpony your idea did the trick. Thanks! To bad I can't just use whatever image type I want any more but that makes sense, and I think all my images are jpeg anyway.
@onetrickpony你的想法成功了。谢谢!为了糟糕,我不能只使用我想要的任何图像类型,但这是有道理的,我认为我的所有图像都是jpeg。