I have a page where it is getting overwhelmed with code like:
var textBox = $get("<%=textState.ClientID%>");
This requires me to have my JavaScript inside the page instead of nicely tucked in a js file. Is there a better approach to this?
document.getElementById doesn't work because then I end up with code like this:
var textBox = document.getElementById("originDestinationControl_textState");
or
var textBox = document.getElementById("ctl00_ContentPlaceHolder_originDestinationControl_textState");
depending on where I am referencing these controls (inside master pages and/or usercontrols)