<p>If I want to manipulate an HTML tag's properties on the server within an aspx page based on a master page i.e. </p>

<pre><code>&lt;a href="#" runat="server" ID="myLink"&gt;My Link&lt;/a&gt;
</code></pre>

<p>For example to give the link a different class depending on the current page i.e.</p>

<pre><code>if (Path.GetFileName(Request.PhysicalPath) == "MyPage")
{
myLink.Attributes.Add("class","active");
}
</code></pre>

<p>.NET changes the ID property of the link to something like</p>

<pre><code>&lt;a href="#" ID="ct100-foo-myLink"&gt;My Link&lt;/a&gt;
</code></pre>

<p>Is there any way of stopping this from happening and keeping the original ID?</p>

<p>Thanks in advance</p>

I don't think so.
However, you probably want to keep the original name so that you can manipulate the control with javascript.... if that's the case, you should look into ClientID; it will return the assigned ID at runtime.
EDIT:
It looks like there is a way to do it, but with some work... take a look at
ASP.NET Controls - Improving automatic ID generation : Architectural Changes ( Part 3)
I didn't read the full post, but it looks like he created his own container and own naming provider.  I think that if you wanted to leave your control's name untouched, you would just return the name back in
```
```
public abstract string SetControlID(string name, System.Web.UI.Control control);
```
```