method to get control in efficient manner
Hi,
We have developed web application for service portal. 10 developers working on this project we have done some JavaScript for client side validation. Here some of the developers using to get the controls values as follows
document.getElementById('<%= txt1.ClientID %>');
Some of them using ClientIDMode="Static"
as static then get the values as
document.getElementById("txt1") à this will not work when we have used ajax update panel.
The remaining set of people using browser generated ID as follows
document.getElementById(ctl00$MainContent$txt1)
I would like to make uniform for this method. Which is the best method to do this.