O'Reilly logo

A Programmer's Guide to .NET by Alexei Fedorov

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

6.9. Web forms’ internals

In this section we will look at how the web form is created by ASP.NET. Let’s create a simple form that contains two fields and a button (see Figure 6.14). The code for this form is shown below.

Figure 6.14. A simple web form with two fields and a button

 <html> <body> <form id="login" runat="server"> <center> <table width="50%"> <tr> <td>User name</td> <td> <input type="text" runat="server" id="uname"> </td> </tr> <tr> <td>Password</td> <td> <input type="password" runat="server" id="pass"> </td> </tr> <tr> <td colspan="2" align="right"> <input type="submit" value="Ok" id="ok" runat="server"> </td> </tr> </table> </center> ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required