I have a master page which has a <form runat="server"> line and a ContentPlaceHolder in it.
I am trying create a content page using this master page whitch has text boxes in it. But I cannot reach values of theese text boxes using Request.Form["textbox"] from that conent page. I need to use Request.Form["ctl00$ContentPlaceHolder1$textbox"].
Is this the normal way to do it? If not what might be I am doing wrong?
By the way I am using same content page to process form values.
So I guess my question is actually: How can I access form values of a Content Page within the same content page?
With ASP.NET, you are not really supposed to know or care about HTTP requests and posted form values. The framework encapsulates these things, allowing you to deal with your
TextBoxas a component in a Windows GUI environment.In your code, you are able to get and set its value using its
Textproperty:Usually, you should only care about the cryptic names and ids of the rendered
<input>elements if you need to add client side code referencing the elements.