Accessing image tag id in javascript when it is placed inside asp server control, Error:The server tag is not well defined
<p>I have code as shown below</p>

<pre><code> &lt;asp:TemplateField FooterStyle-HorizontalAlign="Center" HeaderStyle-HorizontalAlign="Center"
            HeaderStyle-CssClass="Column1"&gt;
            &lt;ItemTemplate&gt;
                &lt;div class="Column1" style="visibility:&lt;%# SetEditImagesVisibility()%&gt;;"&gt;
                    &lt;img src="" id="iEdit"  alt="Edit" class='btntransparent' onclick="EditQC('&lt;%#Eval("ID") %&gt;')" /&gt;
                    &lt;img src="" id="iDelete" alt="Delete" class='btntransparent'  onclick="DeleteQ('&lt;%#Eval("ID") %&gt;')" /&gt;
                &lt;/div&gt;
            &lt;/ItemTemplate&gt;
            &lt;HeaderTemplate&gt;
                &lt;div style="visibility:&lt;%# SetAddImagesVisibility()%&gt;;"&gt;
                    &lt;img src="" alt="Add" class='btntransparent' id="iPlus" runat="server" onclick="AddTestingID()" /&gt;
                &lt;/div&gt;
            &lt;/HeaderTemplate&gt;
        &lt;/asp:TemplateField&gt;
</code></pre>

<p>Here i need to access img tag id in javascript(iEdit and iDelete) but am getting error as
The Server tag is not well defined
javascript code is shown below</p>

<pre><code>  document.getElementsById('iEdit').src = HostedPath + 'pics/edit.gif';
  document.getElementsById('iDelete').src = HostedPath + 'pics/edit.gif';
</code></pre>

<p>Any one please help me out in fixing this issue.
Thanks in advance</p>
