无法在网页中显示图像. [英] Unable to display image in web page.

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

问题描述

你好

我有一个任务,我需要从数据库获取数据到网页.数据将包含表格,普通文本和图像.数据库是TFS 2015的数据库,它具有用于在其中存储工作项描述的表.所以场景是这样的-什么时候 一个人在TFS内手动创建一个工作项,并将其与相应的信息一起存储在数据库中.对于图像和表格,它将信息存储为html标签.

现在,我已经创建了sql查询来获取此数据,并在我的网页中使用了转发器来向用户存储/显示此信息.它适用于表格,它可以将html表格标签显示为数据库中网页中的实际表格.但是它不显示 正确显示图像,它会显示一个带有小图标的小图像图标.我什至无法保存该图像,其图像已损坏.

我不确定应该怎么做才能得到这张图片.

网页代码:

< body>
    < form id ="form1" runat =服务器">
       < asp:标签ID ="lblMessage"; runat =服务器" />< br/>
       < asp:Repeater ID ="rptRequirements" runat =服务器">
           < HeaderTemplate>
                             < table cellpadding ="2" cellspacing ="0" border ="1" style ="border:1px纯灰色">
           </HeaderTemplate>
           < ItemTemplate>
                             < tr< td> b< asp:文字ID ="literal1" runat =服务器"模式=通过".文字='<%#Eval(标题")%>' />/b</td></tr>
                             < tr< td>< asp:文字ID ="literal2" runat =服务器"模式=通过".文字='<%#Eval(说明")%>' />& nbsp;</td></tr>
                             < tr>< td>& nbsp;                      
           </ItemTemplate>
           < AlternatingItemTemplate>
                             < tr> td bgcolor =#CCFFCC"> b< asp:文字ID ="literal1" runat =服务器"模式=通过".文字='<%#Eval(标题")%>' />/b</td></tr>
                             < tr> td bgcolor =#CCFFCC"< asp:文字ID ="literal2" runat =服务器"模式=通过".文字='<%#Eval(说明")%>' />& nbsp;</td></tr>
                             < tr> td bgcolor =#CCFFCC"& nbsp;/td</tr> 
           </AlternatingItemTemplate>
           < FooterTemplate>
                             </table>
           </FooterTemplate>
       </asp:Repeater>
    </form>
</body>

--------------------------------------------------- ------

从数据库中采样记录,请考虑将具有此类数据的重要列之一.

在scr ="之后紧贴图像标签 ,我猜是因为有一个点,图像变得破裂而无法显示.我正在粘贴下面的列内容.当我粘贴代码时,我看不到 scr ="一个点, ,但是它在数据库中可用.我应该怎么做才能在网页上得到图像.

-------------------

< p> p> Ahetejaz测试图像和表格</p> p< br</p> p< img样式=宽度:569.5px"; src ="" ?

FileNameGuid = f3ba6c29-8b64-4fbe-8e90-

9db686205db7& FileName = OLEDB12NotRegistered.png"</p> p< br>//p< p>表

插入的./p>p

/表宽度= 1294 style ="width:972pt; border-collapse:collapse;"边界= 0

cellspacing = 0 cellpadding = 0>< font face ="Times New Roman">

 </font>< colgroup>< col width = 106

style ="width:80pt;">< font face ="Times New Roman"<
 </font>< col width = 166 style ="width:125pt;">< font

face =" Times New Roman">
 </font>< col width = 97 style =" width:73pt;"< font face =" Times New Roman"

</font>< col width = 285 style =" width:214pt;>< font face =" Times New Roman"
 </font>< col width = 355

style ="width:266pt;">< font face ="Times New Roman">
 </font>< col width = 285 style ="width:214pt;">< font

face ="Times New Roman">
<b;</font>< tbody>< tr height = 20 style ="height:15pt;">< font face ='Times New

罗马">
  </font>< td width = 106 height = 20 style ="border:0.5pt实心

windowtext; width:80pt; height:15pt; background-color:yellow;>< strong>< font face = Calibri>要求

ID</font></strong></td>< font face ='Times New Roman'>
  </font>< td width = 166 style =" border-width:0.5pt

0.5pt 0.5pt 0px;边框样式:实心实心无;边框颜色:窗口文字;宽度:125pt;背景-

color:yellow;">< strong>< font face = Calibri>要求
 说明</font></strong></td>< font

face =" Times New Roman">
  </font>< td width = 97 style ="border-width:0.5pt 0.5pt 0.5pt 0px; border-

样式:实心实心无;边框颜色:窗口文字;宽度:73pt;背景-

color:yellow;">< strong>< font face = Calibri>测试用例ID</font></strong></td>< font face ='Times New

罗马">
  </font>< td width = 285 style ="border-width:0.5pt 0.5pt 0.5pt 0px; border-style:solid solid

实心无;边框颜色:窗口文本;宽度:214pt;背景颜色:黄色;>< strong><字体

face = Calibri>测试用例标题</font></strong></td>< font face ='Times New Roman'>
  </font>< td width = 355

style =" border-width:0.5pt 0.5pt 0.5pt 0px; border-style:solid solid solid none; border-

color:windowtext; width:266pt; background-color:yellow;>< strong>< font

face = Calibri>说明</font></strong></td>< font face =" Times New Roman""
  </font>< td width = 285

style =" border-width:0.5pt 0.5pt 0.5pt 0px; border-style:solid solid solid none; border-

color:windowtext; width:214pt; background-color:yellow;>< strong>< font face = Calibri>测试步骤

标题</font></strong></td>< font face ="Times New Roman"<
 </font></tr>< font face ="Times New Roman">

</font>< tr height = 77 style ="height:57.75pt;">< font face =" Times New Roman">
  </font>< td width = 106

height = 77 align = right style ="border-width:0px 0.5pt 0.5pt; border-style:none solid solid; border-

颜色:黑色窗口文本windowtext; width:80pt; height:57.75pt; background-color:transparent;<< font

face = Calibri> 154646</font></td>< font face ='Times New Roman'>
  </font>< td width = 166 style =" border-

width:0px 0.5pt 0.5pt 0px;边框样式:无实心实体无;边框颜色:黑色windowtext windowtext

black; width:125pt; background-color:transparent;>< font face = Calibri>& nbsp;</font></td>< font

face =" Times New Roman">
  </font>< td width = 97 style ="border-width:0px 0.5pt 0.5pt 0px; border-

样式:无实心无;边框颜色:黑色windowtext windowtext黑色;宽度:73pt; background-

color:transparent;">< font face = Calibri>& nbsp;</font></td>< font face =" Times New Roman">
  </font>< td

width = 285 style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-

color:black windowtext windowtext black; width:214pt; background-color:transparent;>< font

face = Calibri>测试用例
  3</font></td>< font face ="Times New Roman"<
  </font>< td width = 355

style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-color:black

windowtext windowtext black; width:266pt; background-color:transparent;>< font face = Calibri& Sample

demo的测试用例br/>   </font>< td

width = 285 style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-

color:black windowtext windowtext black; width:214pt; background-color:transparent;>< font

face = Calibri> Test
 步骤1</font></td>< font face ="Times New Roman"
 </font></tr>< font face ='Times New

罗马">
<b;</font>< tr height = 77 style ="height:57.75pt;"< font face =" Times New Roman"<
  </font>< td

width = 106 height = 77 style =" border-width:0px 0.5pt 0.5pt; border-style:none solid solid; border-

颜色:黑色窗口文本windowtext; width:80pt; height:57.75pt; background-color:transparent;<< font

face = Calibri& nbsp;</font></td>< font face ='Times New Roman'>
  </font>< td width = 166 style =" border-

width:0px 0.5pt 0.5pt 0px;边框样式:无实心实体无;边框颜色:黑色windowtext windowtext

black; width:125pt; background-color:transparent;>< font face = Calibri>& nbsp;</font></td>< font

face =" Times New Roman">
  </font>< td width = 97 style ="border-width:0px 0.5pt 0.5pt 0px; border-

样式:无实心无;边框颜色:黑色windowtext windowtext黑色;宽度:73pt; background-

color:transparent;">< font face = Calibri>& nbsp;</font></td>< font face =" Times New Roman">
  </font>< td

width = 285 style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-

color:black windowtext windowtext black; width:214pt; background-color:transparent;>< font

face = Calibri& nbsp;</font></td>< font face ='Times New Roman'>
  </font>< td width = 355 style =" border-

width:0px 0.5pt 0.5pt 0px;边框样式:无实心实体无;边框颜色:黑色windowtext windowtext

black; width:266pt; background-color:transparent;>< font face = Calibri>& nbsp;</font></td>< font

face =" Times New Roman">
  </font>< td width = 285 style ="border-width:0px 0.5pt 0.5pt 0px; border-

style:none solid solid none; border-color:black windowtext windowtext black; width:214pt; background-

color:transparent;>< font face = Calibri> Test
 步骤2</font></td>< font face ="Times New Roman"

</font></tr>< font face ="Times New Roman">
 </font>< tr height = 77 style ="height:57.75pt;">< font

face =" Times New Roman">
  </font>< td width = 106 height = 77 align = right style ="border-width:0px 0.5pt

0.5pt;边框样式:无纯色;边框颜色:黑色windowtext

windowtext; width:80pt; height:57.75pt; background-color:transparent;>< font

face = Calibri> 154647</font></td>< font face ='Times New Roman'>
  </font>< td width = 166 style =" border-

width:0px 0.5pt 0.5pt 0px;边框样式:无实心实体无;边框颜色:黑色windowtext windowtext

black; width:125pt; background-color:transparent;>< font face = Calibri>& nbsp;</font></td>< font

face =" Times New Roman">
  </font>< td width = 97 style ="border-width:0px 0.5pt 0.5pt 0px; border-

样式:无实心无;边框颜色:黑色windowtext windowtext黑色;宽度:73pt; background-

color:transparent;">< font face = Calibri>& nbsp;</font></td>< font face =" Times New Roman">
  </font>< td

width = 285 style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-

color:black windowtext windowtext black; width:214pt; background-color:transparent;>< font

face = Calibri>测试用例
  4</font></td>< font face ="Times New Roman">
  </font>< td width = 355

style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-color:black

windowtext windowtext black; width:266pt; background-color:transparent;>< font face = Calibri& Sample

demo的测试用例br/>   </font>< td

width = 285 style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-

color:black windowtext windowtext black; width:214pt; background-color:transparent;>< font

face = Calibri> Test
 步骤1</font></td>< font face ="Times New Roman"
 </font></tr>< font face ='Times New

罗马">
<b;</font>< tr height = 77 style ="height:57.75pt;"< font face =" Times New Roman"<
  </font>< td

width = 106 height = 77 align = right style =" border-width:0px 0.5pt 0.5pt; border-style:none solid

纯色;边框颜色:黑色窗口文本;宽度:80pt;高度:57.75pt;背景-

color:transparent;">< font face = Calibri> 154648</font></td>< font face ='Times New Roman'>
  </font>< td

width = 166 style =" border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid none; border-

颜色:黑色windowtext windowtext黑色;宽度:125pt; background-color:transparent;>< font

face = Calibri& nbsp;</font></td>< font face ='Times New Roman'>
  </font>< td width = 97 style =" border-

width:0px 0.5pt 0.5pt 0px;边框样式:无实心实体无;边框颜色:黑色windowtext windowtext

black; width:73pt; background-color:transparent;>< font face = Calibri>& nbsp;</font></td>< font

face =" Times New Roman">
  </font>< td width = 285 style ="border-width:0px 0.5pt 0.5pt 0px; border-

style:none solid solid none; border-color:black windowtext windowtext black; width:214pt; background-

color:transparent;>< font face = Calibri>测试用例
  5</font></td>< font face ="Times New Roman"<

</font>< td width = 355 style ="border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid

无;边框颜色:黑色windowtext窗口文本black; width:266pt; background-color:transparent;>< font

face = Calibri>样品
 演示的测试用例

罗马">
  </font>< td width = 285 style ="border-width:0px 0.5pt 0.5pt 0px; border-style:none solid solid

无;边框颜色:黑色windowtext窗口文本black; width:214pt; background-color:transparent;>< font

face = Calibri> Test
 步骤1</font></td>< font face ="Times New Roman"
 </font></tr>< font face ='Times New

罗马"

</font></tbody</table>< p>< br</p>

-------------------

谢谢.

Ahetejazhamad Khan.


Ahetejazahmad Khan.

解决方案

图像二进制存储在数据库中正确吗?您是在尝试将base64编码的图像嵌入img标签中,还是只是一个链接以检索该图像?可以通过任何一种方式完成,但是很少会在标签中嵌入图片.

< img样式=&;宽度:569.5px;" src ="" ?FileNameGuid = f3ba6c29-8b64-4fbe-8e90-db686205db7& FileName = OLEDB12NotRegistered.png"> 

从上面的标记中,对我来说,好像您要尝试直接从同一页面使用两个参数检索图像:FileNameGuid和FileName.  确保您的后台代码可以处理这样的图像检索.  也考虑 将其移动到应用程序中自己的http处理程序或服务中以获取这些图像.



Hello,

I have a task in which I need to get data from database to web page. Data will contain tables, normal text and images. Database is of TFS 2015 and it has tables which stores work item description in it. So the scenario is something like this - When one creates a work item manually inside TFS its get stored in database with corresponding information. For images and tables it stores the information as html tag.

Now I have created the sql query to get this data and used repeater in my web page to store / display this information to users. It works fine for table, it shows the html table tags as an actual table in web page from database. However its not displaying the image correctly, its shows a small image icon with a break in the icon. I can't even save this image, its kind of broken image.

I am not sure what should be done to get this image.

Web page code:

<body>
    <form id="form1" runat="server">
        <asp:Label ID="lblMessage" runat="server" /><br />
        <asp:Repeater ID="rptRequirements" runat="server">
            <HeaderTemplate>
                <table cellpadding="2" cellspacing="0" border="1" style="border:1px solid gray">
            </HeaderTemplate>
            <ItemTemplate>
                <tr><td><b><asp:Literal ID="literal1" runat="server" Mode="PassThrough" Text='<%#Eval("Title")%>' /></b></td></tr>
                <tr><td><asp:Literal ID="literal2" runat="server" Mode="PassThrough" Text='<%#Eval("Description")%>' />&nbsp;</td></tr>
                <tr><td>&nbsp;</td></tr>                           
            </ItemTemplate>
            <AlternatingItemTemplate>
                <tr><td bgcolor="#CCFFCC"><b><asp:Literal ID="literal1" runat="server" Mode="PassThrough" Text='<%#Eval("Title")%>' /></b></td></tr>
                <tr><td bgcolor="#CCFFCC"><asp:Literal ID="literal2" runat="server" Mode="PassThrough" Text='<%#Eval("Description")%>' />&nbsp;</td></tr>
                <tr><td bgcolor="#CCFFCC">&nbsp;</td></tr> 
            </AlternatingItemTemplate>
            <FooterTemplate>
                </table>
            </FooterTemplate>
        </asp:Repeater>
    </form>
</body>

-----------------------------------------------------

Sample record from database, Considering one of the important column which will have this kind of data.

Noticed the image tag, just after scr = " a dot, I guess because of it the image is getting break and not displayed. I am pasting the column content as it is below. When I pasted the code I don't see scr="a dot, however it is available in the database. What should I do to get the image in the web page.

-------------------

<p>Ahetejaz Test Image and Table </p><p><br></p><p><img style="width:569.5px;" src="?

FileNameGuid=f3ba6c29-8b64-4fbe-8e90-

9db686205db7&amp;FileName=OLEDB12NotRegistered.png"></p><p><br></p><p>Table

inserted.</p><p><br></p><table width=1294 style="width:972pt;border-collapse:collapse;" border=0

cellspacing=0 cellpadding=0><font face="Times New Roman">

 </font><colgroup><col width=106

style="width:80pt;"><font face="Times New Roman">
 </font><col width=166 style="width:125pt;"><font

face="Times New Roman">
 </font><col width=97 style="width:73pt;"><font face="Times New Roman">

</font><col width=285 style="width:214pt;"><font face="Times New Roman">
 </font><col width=355

style="width:266pt;"><font face="Times New Roman">
 </font><col width=285 style="width:214pt;"><font

face="Times New Roman">
 </font><tbody><tr height=20 style="height:15pt;"><font face="Times New

Roman">
  </font><td width=106 height=20 style="border:0.5pt solid

windowtext;width:80pt;height:15pt;background-color:yellow;"><strong><font face=Calibri>Requirement

ID</font></strong></td><font face="Times New Roman">
  </font><td width=166 style="border-width:0.5pt

0.5pt 0.5pt 0px;border-style:solid solid solid none;border-color:windowtext;width:125pt;background-

color:yellow;"><strong><font face=Calibri>Requirement
  Description</font></strong></td><font

face="Times New Roman">
  </font><td width=97 style="border-width:0.5pt 0.5pt 0.5pt 0px;border-

style:solid solid solid none;border-color:windowtext;width:73pt;background-

color:yellow;"><strong><font face=Calibri>Test Case ID</font></strong></td><font face="Times New

Roman">
  </font><td width=285 style="border-width:0.5pt 0.5pt 0.5pt 0px;border-style:solid solid

solid none;border-color:windowtext;width:214pt;background-color:yellow;"><strong><font

face=Calibri>Test Case Title</font></strong></td><font face="Times New Roman">
  </font><td width=355

style="border-width:0.5pt 0.5pt 0.5pt 0px;border-style:solid solid solid none;border-

color:windowtext;width:266pt;background-color:yellow;"><strong><font

face=Calibri>Description</font></strong></td><font face="Times New Roman">
  </font><td width=285

style="border-width:0.5pt 0.5pt 0.5pt 0px;border-style:solid solid solid none;border-

color:windowtext;width:214pt;background-color:yellow;"><strong><font face=Calibri>Test Step

Title</font></strong></td><font face="Times New Roman">
 </font></tr><font face="Times New Roman">

</font><tr height=77 style="height:57.75pt;"><font face="Times New Roman">
  </font><td width=106

height=77 align=right style="border-width:0px 0.5pt 0.5pt;border-style:none solid solid;border-

color:black windowtext windowtext;width:80pt;height:57.75pt;background-color:transparent;"><font

face=Calibri>154646</font></td><font face="Times New Roman">
  </font><td width=166 style="border-

width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-color:black windowtext windowtext

black;width:125pt;background-color:transparent;"><font face=Calibri>&nbsp;</font></td><font

face="Times New Roman">
  </font><td width=97 style="border-width:0px 0.5pt 0.5pt 0px;border-

style:none solid solid none;border-color:black windowtext windowtext black;width:73pt;background-

color:transparent;"><font face=Calibri>&nbsp;</font></td><font face="Times New Roman">
  </font><td

width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-

color:black windowtext windowtext black;width:214pt;background-color:transparent;"><font

face=Calibri>Testcase
  3</font></td><font face="Times New Roman">
  </font><td width=355

style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-color:black

windowtext windowtext black;width:266pt;background-color:transparent;"><font face=Calibri>Sample

test case for demo<span style="">&nbsp;</span></font></td><font face="Times New Roman">
  </font><td

width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-

color:black windowtext windowtext black;width:214pt;background-color:transparent;"><font

face=Calibri>Test
  step 1</font></td><font face="Times New Roman">
 </font></tr><font face="Times New

Roman">
 </font><tr height=77 style="height:57.75pt;"><font face="Times New Roman">
  </font><td

width=106 height=77 style="border-width:0px 0.5pt 0.5pt;border-style:none solid solid;border-

color:black windowtext windowtext;width:80pt;height:57.75pt;background-color:transparent;"><font

face=Calibri>&nbsp;</font></td><font face="Times New Roman">
  </font><td width=166 style="border-

width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-color:black windowtext windowtext

black;width:125pt;background-color:transparent;"><font face=Calibri>&nbsp;</font></td><font

face="Times New Roman">
  </font><td width=97 style="border-width:0px 0.5pt 0.5pt 0px;border-

style:none solid solid none;border-color:black windowtext windowtext black;width:73pt;background-

color:transparent;"><font face=Calibri>&nbsp;</font></td><font face="Times New Roman">
  </font><td

width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-

color:black windowtext windowtext black;width:214pt;background-color:transparent;"><font

face=Calibri>&nbsp;</font></td><font face="Times New Roman">
  </font><td width=355 style="border-

width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-color:black windowtext windowtext

black;width:266pt;background-color:transparent;"><font face=Calibri>&nbsp;</font></td><font

face="Times New Roman">
  </font><td width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-

style:none solid solid none;border-color:black windowtext windowtext black;width:214pt;background-

color:transparent;"><font face=Calibri>Test
  step 2</font></td><font face="Times New Roman">

</font></tr><font face="Times New Roman">
 </font><tr height=77 style="height:57.75pt;"><font

face="Times New Roman">
  </font><td width=106 height=77 align=right style="border-width:0px 0.5pt

0.5pt;border-style:none solid solid;border-color:black windowtext

windowtext;width:80pt;height:57.75pt;background-color:transparent;"><font

face=Calibri>154647</font></td><font face="Times New Roman">
  </font><td width=166 style="border-

width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-color:black windowtext windowtext

black;width:125pt;background-color:transparent;"><font face=Calibri>&nbsp;</font></td><font

face="Times New Roman">
  </font><td width=97 style="border-width:0px 0.5pt 0.5pt 0px;border-

style:none solid solid none;border-color:black windowtext windowtext black;width:73pt;background-

color:transparent;"><font face=Calibri>&nbsp;</font></td><font face="Times New Roman">
  </font><td

width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-

color:black windowtext windowtext black;width:214pt;background-color:transparent;"><font

face=Calibri>Testcase
  4</font></td><font face="Times New Roman">
  </font><td width=355

style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-color:black

windowtext windowtext black;width:266pt;background-color:transparent;"><font face=Calibri>Sample

test case for demo<span style="">&nbsp;</span></font></td><font face="Times New Roman">
  </font><td

width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-

color:black windowtext windowtext black;width:214pt;background-color:transparent;"><font

face=Calibri>Test
  step 1</font></td><font face="Times New Roman">
 </font></tr><font face="Times New

Roman">
 </font><tr height=77 style="height:57.75pt;"><font face="Times New Roman">
  </font><td

width=106 height=77 align=right style="border-width:0px 0.5pt 0.5pt;border-style:none solid

solid;border-color:black windowtext windowtext;width:80pt;height:57.75pt;background-

color:transparent;"><font face=Calibri>154648</font></td><font face="Times New Roman">
  </font><td

width=166 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-

color:black windowtext windowtext black;width:125pt;background-color:transparent;"><font

face=Calibri>&nbsp;</font></td><font face="Times New Roman">
  </font><td width=97 style="border-

width:0px 0.5pt 0.5pt 0px;border-style:none solid solid none;border-color:black windowtext windowtext

black;width:73pt;background-color:transparent;"><font face=Calibri>&nbsp;</font></td><font

face="Times New Roman">
  </font><td width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-

style:none solid solid none;border-color:black windowtext windowtext black;width:214pt;background-

color:transparent;"><font face=Calibri>Testcase
  5</font></td><font face="Times New Roman">

</font><td width=355 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid

none;border-color:black windowtext windowtext black;width:266pt;background-color:transparent;"><font

face=Calibri>Sample
  test case for demo<span style="">&nbsp;</span></font></td><font face="Times New

Roman">
  </font><td width=285 style="border-width:0px 0.5pt 0.5pt 0px;border-style:none solid solid

none;border-color:black windowtext windowtext black;width:214pt;background-color:transparent;"><font

face=Calibri>Test
  step 1</font></td><font face="Times New Roman">
 </font></tr><font face="Times New

Roman">

</font></tbody></table><p><br></p>

-------------------

Thank you.

Ahetejazhamad Khan.


Ahetejazahmad Khan.

解决方案

The image binary is stored IN the database correct? Are you trying to embed the base64 encoded image in the img tag or just a link to retrieve the image? It can be done either way but very rarely is the image embedded in the tag.

<img style="width:569.5px;" src="?FileNameGuid=f3ba6c29-8b64-4fbe-8e90-db686205db7&amp;FileName=OLEDB12NotRegistered.png">

From your markup above it appears to me as if you are trying to retrieve the image directly from the same page with two parameters: FileNameGuid and FileName.  Make sure your code-behind can handle retrieving the images like this.  Also consider moving this to it's own http handler or service inside your application to get get these images. 



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

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