Hi Guys,
i have a doubt were i am collecting info from a form with textboxes with run at server, but these textboxes values are being passed to a javascript function which in turn routes these values to a web method in ASP.net code behind so my business process can then execute. in this case do i have to use the run at server??
Thanks
use or not use runat = "server"
Page 1 of 13 Replies - 544 Views - Last Post: 07 January 2013 - 02:30 AM
Replies To: use or not use runat = "server"
#2
Re: use or not use runat = "server"
Posted 05 January 2013 - 04:01 PM
I'm not sure, But mainly i always use the tag runat="server"
ASP.NET parser interpretes standard html elements w/ runat="server" tag as html server controls.
All HTML server controls must be within a <form> tag with the runat="server" attribute. The runat="server" attribute indicates that the form should be processed on the server. It also indicates that the enclosed controls can be accessed by server scripts.
ASP.NET parser interpretes standard html elements w/ runat="server" tag as html server controls.
All HTML server controls must be within a <form> tag with the runat="server" attribute. The runat="server" attribute indicates that the form should be processed on the server. It also indicates that the enclosed controls can be accessed by server scripts.
#3
Re: use or not use runat = "server"
Posted 05 January 2013 - 09:15 PM
if the textboxes are not being used in the code on the server side then there is not really a need for the runat=server, just use standard html textboxes.
#4
Re: use or not use runat = "server"
Posted 07 January 2013 - 02:30 AM
Well what the runat="server" does is tells the compiler that specific tag needs to run on the server server-side.
If that attribute wasn't present, then it assumes it is regular markup and passes it to the client.
Also, here is a very informative thread where your question is analyzed in several ways and has different viewpoints. Do take a look
regards,
Raghav
If that attribute wasn't present, then it assumes it is regular markup and passes it to the client.
Also, here is a very informative thread where your question is analyzed in several ways and has different viewpoints. Do take a look
regards,
Raghav
Page 1 of 1
|
|

New Topic/Question
Reply




MultiQuote




|