内部采用HTML与ASP:按钮? [英] Using Inner HTML with an ASP:Button?
本文介绍了内部采用HTML与ASP:按钮?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我如何转换
<button type="submit" class="blue">
<span>Login</span>
</button>
进入一个ASP按钮?
Into an asp button?
<asp:Button ID="Button1" runat="server" Text="Button" />
<asp:LinkButton ID="LinkButton1" runat="server" CssClass="blue"><span>Login</span></asp:LinkButton>
我根本无法找到一个方法来做到这一点。对不起它的一个蹩脚的问题,但它扔我一个循环,可能只需要在它睡觉了。
I just simply cannot find a way to do it. Sorry its a crappy question, but it's throwing me for a loop, might just need to sleep on it.
推荐答案
如果你真的需要丰富的格式要么你使用一个CSS类,并在侧面的CSS定义所有的造型,也可以使用HTML锚
我不知道的另一种方式来组成一个按钮或LinkButton控件的内部HTML像你正在尝试做的。
If you really need rich formatting either you use a css class and define all styling in the css side or you can use an html anchor
I am not aware of another way to compose the inner html of a button or linkbutton like you are trying to do.
这篇关于内部采用HTML与ASP:按钮?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文