日期:2014-05-17  浏览次数:20518 次

imagebutton控件的问题求教!
想鼠标放到imagebutton上面就更换图片,是用onmouseover然后在JS中写个function对吧。但是我的imagebutton控件是在datalist中的,在实际测试中鼠标放到imagebutton并没有反应。这是怎么回事。我在单独的测试imagebutton都可以变化图片的。
<asp:DataList ID="DataList1" runat="server" RepeatColumns="1">
            <ItemTemplate>
                <table style="width:100%;">
                    <tr>
                        <td colspan="2">
                            <asp:Label ID="Label1" runat="server"  Text='<%# Eval("ProductName") %>'></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td rowspan="8">
                            <asp:Image ID="Image1" runat="server" ImageUrl='<%# Eval("Imgurl") %>' />
                        </td>
                        <td>
                            商品ID:<asp:Label ID="Label2" runat="server"    Text='<%# Eval("ProductID") %>'></asp:Label>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            价格: ¥<asp:Label ID="Label3" runat="server"    Text='<%# Eval("Price") %>'></asp:Label>
                        </td>
                    </tr>
           &nb