我使用以下代码,但它无法正常工作.告诉我是否有任何建议.我想在加载页面时取消选中所有chekbox.我有以下代码,但它不起作用:
window.onload = function abc() {
document.getElementsByTagName('input')[0].focus();
}
Run Code Online (Sandbox Code Playgroud)
<tr>
<td>
<input type="checkbox" ID="cb1" value="29500" onclick="if(this.checked){ cbcheck(this) } else { cbuncheck(this)}" /> Laptop
</td>
<td>
<a href="#" id="a1" onmouseover="showimage('a1','laptop1');" >Show Image</a>
<img src="Images/laptop.jpg" id="laptop1" alt="" style="display:none; width:150px; height:150px;" onmouseout="hideimage('a1','laptop1');" class="right"/>
</td>
</tr>
<tr>
<td>
<input type="checkbox" ID="cb2" value="10500" onclick="if(this.checked){ cbcheck(this) } else { cbuncheck(this)}" /> Mobile
</td>
<td>
<a href="#" id="a2" onmouseover="showimage('a2','mobile1');" >Show Image</a>
<img src="Images/mobile.jpg" id="mobile1" alt="" style="display:none; width:150px; height:150px;" onmouseout="hideimage('a2','mobile1');" />
</td>
</tr>
Run Code Online (Sandbox Code Playgroud) <ItemTemplate>
<asp:Label ID="lblCompanyName" runat="server"
ToolTip='<%# CheckDbNull.ToStr(Eval("Name")) %>'
Text='<%# CheckDbNull.ToStr(Eval("Name")) %>'>
</asp:Label>
</ItemTemplate>
Run Code Online (Sandbox Code Playgroud)
我有一些HTML格式的数据,例如<abc>
,<Name>
等,但是它将呈现为HTML,并且不会显示。
如何在网格列中显示HTML文本?我正在使用Telerik:RadGrid
和模板列。