无法在Mozilla Firefox中显示图像 [英] Unable to Display Image in Mozilla Firefox

查看:84
本文介绍了无法在Mozilla Firefox中显示图像的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的所有人,
我在ASP.NET中使用"img"控件来显示图像.我为imageurl分配了来自数据库的图像文件路径,如下所示:

Dear All,
I am using ''img'' control in ASP.NET to display images. I am assigning the imageurl with the image file path coming from database as below:

imgMain.ImageUrl = ImagePath;


该程序使用Internet Explorer运行并从URL加载图像.很好.

但是,当要与mozilla Firefox一起运行时,图像不会显示在图像面板"中.请帮帮我.

代码是:


This program run and load images from URL with Internet Explorer. Fine.

But when want to run with mozilla Firefox, image is not shown in Image Panel. Please help me.

Code is:

//Funtion in Client side as like below:
function fnSetImage(filepath)
{
     document.getElementById('<%=imgMain.ClientID%>').src=filepath;
     return false;
}

推荐答案



请把../放在您的图像路径上,例如

Hi,

Please put ../ on your image path like

//Funtion in Client side as like below:
function fnSetImage(filepath)
{
     document.getElementById('<%=imgMain.ClientID%>').src= '../' + filepath;
     return false;
}




如有任何疑问,请让我知道.

如果有帮助,请提供"投票",如果这是正确的答案,请提供"接受答案".:rose:

谢谢,
Imdadhusen




Please do let me know, if you have any doubt.

Please provide "Vote" if this would be helpful, and make "Accept Answer" if this would be correct answer.:rose:

Thanks,
Imdadhusen


这篇关于无法在Mozilla Firefox中显示图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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