我如何...图像无法加载空间 [英] How do I... image not load with space

查看:64
本文介绍了我如何...图像无法加载空间的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嗨我有图片我的网址:



hi i have image i url :

D:\Project\Web Project\Nezam V3\Nezam V3\Photo\df428.jpg





我在页面中的代码是:



and my code in page is :

<img height="50" width="50" src="@HttpUtility.UrlPathEncode(item.ImageUrl) ">





现在我的图片没有加载?



now my images not load ?

推荐答案

你不能使用物理路径作为src值。查看 http://www.w3schools.com/tags/att_img_src.asp [ ^ ]

you can't use physical path as src value. check http://www.w3schools.com/tags/att_img_src.asp[^]
Quote:

可能的值:



绝对URL - 指向另一个网站(如src =http:// www .example.com / image.gif)

相对URL - 指向网站中的文件(如src =image.gif)

Possible values:

An absolute URL - points to another web site (like src="http://www.example.com/image.gif")
A relative URL - points to a file within a web site (like src="image.gif")


这篇关于我如何...图像无法加载空间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆