I have a web form with usual elements (first name, last name, etc). The Postback URL is a different website altogether as the form is intented to post lead information to another website.
The site that accepts the lead is expecting First Name to come over as "FName", and Last Name to come over as "LName". Is there any way I can set the ID of a textbox to "txtFName", but submit it over the wire as "FName"? I tried changing the na开发者_运维问答me attribute, but at runtime it sets the name = id.
You should use normal (non-runat="server"
) <input>
elements.
You will then have complete control over the name and id.
for 'standard-html-input-elements', the name attribute, is the one being submitted, the id-attribute may be used e.g. in javascript.
精彩评论