jquery - Firefox 上的 div 问题中的图像

标签 jquery asp.net css styles

我有以下通过 jquery 动态生成的布局。基本上它创建了一堆带有图像的 div,div 向左浮动。在 Chrome 和 IE 上图像加载正确,但在 FireFox 上图像不加载。如果我尝试检查图像,FireFox 会说 src 加载失败。有什么想法吗?

 <div id="divButton" class="buttonToolBar">
   <img src="..." alt="buttonType" />
 </div>

.buttonToolBar
{
    float:left;
    border-color: #CCCCCC #999999 #999999 #CCCCCC;
    border-style: solid;
    border-width: 1px;
    margin: 1px 2px;
}

enter image description here对比enter image description here

更新 这是其中一张图片的网址示例 http://localhost:7499/CuteSoft_Client/CuteEditor/Themes/Office2007/Images/table.gif

更新 我在服务器端使用 ResolveClientUrl 方法来呈现正确的 url,也许这就是问题所在?

最佳答案

我在 Firefox 上看到当您在图像上输入错误的斜杠时会发生这种情况。

例如这有效 /img/oneimage.jpg \img\oneimage.jpg

关于jquery - Firefox 上的 div 问题中的图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6604474/

相关文章:

html - 无法使悬停工作

css - 使用 Compass 进行多重转换

javascript - 表单未在 ajax 从 php 返回的 html 数据中提交

javascript - jQuery - 从数组中获取元素作为 jQuery 元素?

c# - 尝试为文件 xxxx 附加自动命名的数据库失败

html - 选择第二个复选框也会选择第一个

php - 从php中的文件目录中删除文件扩展名

javascript - jQuery : If url contains string x change backgroud color of specific tag

c# - 正则表达式匹配IP地址+通配符

javascript - 在 IE11 中取消 JavaScript 事件