数据库里存的是一段html标签,绑定到gridview里面展示的时候会把html标签解析,怎么才能把数据作为字符串输出?
<asp:GridView ID="gv_documentList" runat="server" AutoGenerateColumns="False" Width="100%"
AllowPaging="True" OnRowDataBound="gv_Product_RowDataBound"
OnPageIndexChanging="gv_Product_PageIndexChanging"
onrowcommand="gv_Product_RowCommand">
<Columns>
<asp:TemplateField HeaderText="视频名称">
<ItemTemplate>
<%#Eval("VideoName")%>
</ItemTemplate>
<ItemStyle HorizontalAlign="Center" />
</asp:TemplateField>
<asp:TemplateField HeaderText="视频地址">
<ItemTemplate>
<span><%#Eval("VideoContent")%></span>
</ItemTemplate>
<ItemStyle HorizontalAlign="Center" />
</asp:TemplateField>
<asp:TemplateField>
<ItemTemplate>
<asp:LinkButton ID="lbtn_delete" runat="server" CommandName="del" CommandArgument='<%#Eval("VideoId") %>'>删除</asp:LinkButton>
</ItemTemplate>
<ItemStyle HorizontalAlign="Center"/>
</asp:TemplateField>
</Columns>
</asp:GridView> |