访问asp.net中文件夹外部的图像路径? [英] access image path outside folder in asp.net?

查看:98
本文介绍了访问asp.net中文件夹外部的图像路径?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我在名为members的文件夹中有一个aspx页面,在名为images的文件夹中有images.但是aspx页面无法访问images.I尝试:

../images/a.jpg

〜/images/a.jpg

/images/a.jpg

但没有任何效果.
那么解决方案是什么呢?

Hi ,

i have an aspx page inside a folder called members and images inside a folder called images.But the aspx page is not able to access the images.I tried:

../images/a.jpg
and
~/images/a.jpg
and
/images/a.jpg

but nothing is working.
So what is the solution ?

推荐答案

这应该可行
This should work
<img src="../images/a.png" />


此技巧可能会有所帮助:

解析多文件夹网站中的路径 [ ^ ]
This tip may help:

Resolving Paths in a Multi-Folder WebSite[^]


这篇关于访问asp.net中文件夹外部的图像路径?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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