How to have html in Text attribute of asp Button

What I ended up doing was going with an html button, runat=server and putting the <i> inside of that.

<button runat="server" id="modify" class="btn btn-mini" title="Modify" onserverclick="modify_Onclick">
    <i class="icon-edit"></i>
</button>

You can use <asp:LinkButton. Bootstrap renders anchor tags (asp:LinkButton) like input type submit buttons (asp:Button).

<asp:LinkButton runat="server" ID="modify" ToolTip="Modify" CssClass="btn btn-mini" OnClick="modify_Onclick" Text='<i class="icon-edit"></i>' />

Tags:

Asp.Net