Javascript for Datalist control in asp.net?
<p>In Web application, i write javacript for mouse over and mouseout for a button to change the color. It is not working when button is in datalist control, it is working fine when button is out side of datalist control. this is my code please help me. thank you.</p>

<pre><code>  &lt;script type="text/javascript" &gt;
function changeImage() 
{       
    document.getElementById("btnView").style.background = "#AD1F13";
}
</code></pre>

<p>function changeImage1()
   {
     document.getElementById("btnView").style.background = "#005594";
   } 
   </p>

<pre><code>&lt;asp:DataList ID="dtlstMagazine" class='tableborder'    runat ="server" Width ="100%" 
          onitemdatabound="dtlstMagazine_ItemDataBound" 
          onitemcommand="dtlstMagazine_ItemCommand"&gt;
       &lt;ItemTemplate &gt;
            &lt;div style="text-align:left; " class="item-title"  &gt;
 &lt;asp:LinkButton Font-Underline ="false"   ID="ltrlTitle"   CommandName="Redirect"  CommandArgument='&lt;%# Eval("titleid") %&gt;' Font-Bold ="true" Font-Size ="Medium"         runat="server" Text ='&lt;%# Eval("Title") %&gt;'&gt;&lt;/asp:LinkButton&gt; 
                                      &lt;/div&gt;                            
             &lt;asp:Button ID="Btn_CR1" runat="server" Text="Continue Reading"   CssClass='button3'  onMouseOver="changeImage()" onMouseOut="changeImage1()" /&gt;  &lt;/ItemTemplate&gt;  &lt;/asp:DataList&gt;
</code></pre>
