gpt4 book ai didi

c# - c# asp.net 3.5 中图像按钮上的文本

转载 作者:行者123 更新时间:2023-12-04 02:35:43 25 4
gpt4 key购买 nike

我有一个图像按钮。我想在上面添加一个文本“搜索”。我无法添加它,因为 VS 2008 中的“imagebutton”属性中没有文本控件。谁能告诉我如何向图像按钮添加文本?

  <asp:ImageButton ID="Searchbutton" runat="server" AlternateText="Search" 
CssClass="bluebutton"
ImageUrl="../Graphics/bluebutton.gif" Width="110px"
onclick="Searchbutton_Click"/>

最佳答案

<button runat="server" 
style="background-image:url('/Content/Img/stackoverflow-logo-250.png')" >
your text here<br/>and some more<br/><br/> and some more ....
</button>

关于c# - c# asp.net 3.5 中图像按钮上的文本,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/262141/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com