What language do you use? You can do it in C # using
<input type="text" name="txtNAME1" displayName="dname1" runat="server" id="test" />
Then in the code behind:
test.Attributes["displayName"];
You can also access it in jQuery with
$('test').attr('displayName')
and send it to the server through the handler.
source share