Web Programming is the process of creating Internet Applications. Any application that uses the Internet in a way, can be considered an Internet application. They can be classified into four common categories:-
Web Applications - Applications based on the Client/Server architecture over the Internet.
The Client/Server architecture is composed of a server, which is responsible for providing services to the other computer systems - Clients. Typically, there is a single server which handles requests from multiple clients and responds to these requests by providing the client with the appropriate information.
In a Web Application, the server is the machine where the web page is stored and the clients employ web browsers to view the application. Such a server is called a Web Server.
Web Services - Web Services are components that expose processing services from a server to other applications over the Internet. The services themselves are executed remotely in the server hosting them.
Internet Enabled Applications - Any stand-alone application that uses the Internet falls into this category. Such an an application uses the Internet for online Registration/Activation, Help, Updates, etc.
Peer-to-Peer Applications - These are stand-alone applications that use the Internet to communicate with other users running their own instances of the application. They use decentralized network architecture where there is no central server, rather individual nodes. Examples of such applications can include the famous Bit Torrent client.
Note:- In this tutorial, we would be involved with Web Application only.
Working of the Web Applications
As mentioned before, the client side of the Web Application includes a web browser, which interprets Hypertext Markup Language (HTML) transferred by the server and displays the user interface. The server itself runs the web applications under Microsoft Internet Information Services (IIS) which is responsible for managing the application, passing request from clients to the application and returning the application's responses to the client. The intricate communication involved in this process is done by using a standard set of rules (Protocols) known as the Hypertext Transfer Protocol (HTTP).
The responses generated by the Web application is made from the resources (Executable code running on the server, Web Forms, HTML pages, images and other media files) found on the server. These responses are similar to traditional Web sites with HTML pages, except that they are dynamically generated. Consider a university's web site which releases the exam results. Do they take the pain of creating different HTML pages for each of the student's mark sheet? No, they use web applications to retrieve data (marks, subjects, student name, roll no, etc) from a database and dynamically generate the HTML output which is then sent to the client's browser.
The executable portion of the Web application is responsible for overcoming the limitations of static web pages. They can be used to:-
- Collect information from the user and store the information on the server (in a database).
- Performing tasks for the user such as placing an order for a product, performing complex calculations, or retrieving information from a database.
- Identify a user and present customized user interface.
ASP .NET is the platform that allows us to create Web applications and services that run under IIS. One must note that ASP .NET is NOT the only platform to develop Web applications. Other platforms such as Common Gateway Interface (CGI) can also be used to create Web applications. ASP .NET is unique in the way it is tightly integrated with Microsoft server, programming, data access and security tools. It forms a part of the Microsoft .NET suite of products and is composed of:-
- Visual Studio .NET Web Development Tools - These are Graphical User Interface (GUI) based tools to facilitate easy designing of Web pages using What You See Is What You Get (WYSIWYG) editors, project management and deployment tools.
- The System.Web namespaces - These form a part of the .NET Framework Base class libraries and include the programming classes that deal with Web specific items such as HTTP requests and responses, browsers and e-mail.
- Server and HTML Controls - The user interface components such as Text Box, label, Button, ListBox, etc. that are used to gather information from and provide to users.
- Microsoft ADO.NET database classes and tools - Database access is one of the key components of modern Web applications. These tools provide methods to access and use Microsoft SQL Server and ODBC databases.
- Microsoft Application Center Test (ACT) - Testing environment for Web applications.
Why Choose ASP .NET?
The following are the advantages that ASP .NET has over other platforms:-
- Faster execution - Executable portions of Web applications are compiled to facilitate faster performance.
- On the fly updates of deployed Web applications thus preventing the need to restart the server.
- The amount of code to be written is greatly reduced because of the access to .NET Framework base class libraries which includes classes and methods to perform common operations.
- Language independent - Developers have the choice to write codes in the friendly Visual Basic programming language or the type safe C# language. Other third party .NET compliant languages can also be used.
- Automatic state management for controls on a web page (server controls) makes the controls behave more like the Windows controls.
- New controls can be created and existing controls can be extended.
- Built in security through the Windows server or through other authentication/authorization methods.
- Integration with ADO .NET to provide database access and database design tools from within Visual Studio .NET
- Full support for Extensible Markup Language (XML) and Cascading Style Sheets (CSS)
- Automatic intelligent caching of frequently requested Web pages, localizing content for specific languages and cultures and detecting browser capabilities.
Previous Tutorial - The .NET Framework & CLR : Basic Introduction
Edited by turbopowerdmaxsteel, 06 April 2007 - 09:35 AM.