0

悬停有效,但仅适用于按钮图像的某些部分或按钮图像之外。此外,如果箭头从上方进入按钮,则悬停不起作用。

有任何想法吗?

.buttonSearch{
display: block;
background:   url("../Images/btn Search.JPG") no-repeat top;
height: 40px;
width:100px;
border:1px solid #7AB800;
border-width:0px;
margin-left: 210px;}



.buttonSearch:hover
{display: block;
    background: transparent url("../Images/btn Search Click2.JPG") no-repeat top;
    height: 40px;
    width:100px;
    border:none 0 transparent;
   border-width:0px;
   margin-left: 210px;

ASP页面:

<ajaxToolkit:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
    </ajaxToolkit:ToolkitScriptManager>

<asp:Panel ID="p" runat="server" DefaultButton="butName">
<br />
<br />

<asp:Label ID="TextBox1" runat="server" AutoComplete="Off" CssClass="display-labelsearch" Text="Last Name: " />
<asp:TextBox ID="txtName" runat="server" CssClass="display-fieldsearch" MaxLength="100" ToolTip="Please enter a Provider last name."></asp:TextBox>
        <cc1:TextBoxWatermarkExtender ID="txtName_TextBoxWatermarkExtender" 
        runat="server" Enabled="True" TargetControlID="txtName" WatermarkText="Type Last Name Here"  WatermarkCssClass="watermarked">
        </cc1:TextBoxWatermarkExtender>
        <cc1:AutoCompleteExtender ID="AutoCompleteExtender1" runat="server"
        TargetControlID="txtName" MinimumPrefixLength="1" ServiceMethod="GetNames" 
        UseContextKey="True">
        </cc1:AutoCompleteExtender>
</asp:Panel>
<asp:Button ID="butName" runat="server" onclick="tbSearchbutton" CssClass="buttonSearch" />




 <asp:GridView ID="gvProvLookup" runat="server" 

AutoGenerateColumns="False" OnRowCommand="ViewProv_RowCommand" yada yada

4

1 回答 1

0

有东西覆盖了按钮的一部分。我把它移了一条线,它工作正常。

于 2013-07-24T21:13:27.743 回答