Join David Gassner for an in-depth discussion in this video Understanding how ASP.NET works, part of ASP.NET Essential Training.
ASP.NET is one of the family of software packages known as application servers. An application server is a piece of software that's installed on a web server to create a dynamic application platform. The world wide web includes many clients and servers that are connected over the Internet. Technically speaking, they communicate using a protocol called TCP/IP. This is the protocol that connects all of the computers in the whole world together. When these computers talk to each other, they exchange messages in a format known as HTTP, which stands for HyperText Transfer Protocol. This sort of communication is used whether you are working with a static website, that is a website that delivers static fixed web pages, or a dynamic web application such as those that are supported by ASP.NET.
Here is how a static web page works. The web client makes a request for the resource, let's say a web page, by sending an HTTP formatted request over the Internet to the server. The server responds by locating the file on its hard disk that has been requested. This is known as a static web page with a file extension of typically of .htm or .html. The web server responds by sending that content back to the client and the client, which might be a web browser on a personal computer, renders and displays the web page visually.
When you move to the dynamic environment, the application server software is installed on the same computer as the web server. Let's say Internet Information Services and ASP.NET. The application server, in this case ASP.NET, can communicate with the database and with other server resources. Once again, the web client makes the HTTP formatted request. The web server talks to the application server. The application server talks to the database and other network resources and then it's up to the web server to construct an HTML formatted response, which once again is sent back to the web client.
The important thing here is that the web browser doesn't know that there is an application server at work and therefore doesn't need any additional software. It requests an HTML page and it receives an HTML page and it doesn't know the difference between one that's static and fixed on the server's hard disk and one that's being generated dynamically in response to which request. There are many software packages that you can select from as application servers. If you are watching this video series, you have probably already selected ASP.NET or you are evaluating it for possible use in your organization. Microsoft Active Server Pages or ASP is another option that you might select. Active Server Pages is an older version of Microsoft's Application Server Technology.
You can also select Adobe ColdFusion, a cross operating system product that works on many operating systems including Windows, Mac and Linux and that uses its own proprietary language, ColdFusion Markup Language. Some developers use PHP, a completely free and open source product that once again is available on many operating systems. And for Java developers, there are many application server products available including Websphere from IBM, Weblogic from Oracle, formerly from BEA, JBoss, a completely free J2EE or Java-based server and others, and finally there is Microsoft's ASP.NET.
So that's a look at the basic architecture of ASP.NET. In another videos in this chapter, I describe how to install ASP.NET along with the product called Visual Web Developer, an integrated development environment that can get you started quickly building ASP.NET-based, dynamic web applications.
- Storing data with SQL Server
- Using the GridView control to present and edit dynamic data
- Creating a data entry system
- Attaching external CSS files
- Creating pages to log in and authenticate visitors
- Installing Internet Information Services (IIS) on Windows XP and Windows Vista
- Deploying an ASP.NET website on IIS
Skill Level Beginner
Q: When trying to create a new database, after pasting the text into the SQL Management Suite and executing the query, the database is not created and the following message appears:
Database 'mybookstore' does not exist. Make sure that the name is entered correctly.
What is causing this error?
A: The database must be explicitly created before the script is run. Start by right-clicking on the Databases item in the left panel, then follow the prompts to create the database. Then retry the query.
Q: I am running into problems installing the latest version of ASP.NET. Has the installation procedure changed since this tutorial was recorded?
A: The installation process for the newest version of ASP.NET and its associated tools is a little different than in ASP.NET 3.5, which was used to record this course. You can download Microsoft Web Platform Installer 2.0 from:
<a href="http://www.microsoft.com/web/downloads/platform.aspx" target="blank">http://www.microsoft.com/web/downloads/platform.aspx</a>
Microsoft Web Platform Installer 2.0 includes everything you need:
Visual Web Developer 2010?
SQL Server Express
You must have one of the following operating systems:
Windows Vista SP1?
Windows XP SP2+?
Windows Server 2003 SP1+?
Windows Server 2008?
Windows Server 2008 R2
You must have administrator privileges on your computer to run the Web Platform Installer.
Q: This course was updated on 2/13/2013. What changed?
A: Since this course was recorded, Microsoft has released both ASP.NET 4.5, the latest version of the server-side web application server, and Visual Studio Express 2012 for Web (the successor product to Visual Web Developer). Both have been adapted to work on Windows 8. There will be some visual changes and some functional changes, but most of the server-side code shown in the course is the same. This update provides a map for those working with the latest software so they can navigate their way through the course.
In particular, we added <em>What's new</em> movies for both ASP.NET 4 and 4.5, a movie explaining the significance of the update, a movie on installing SQL Server Express 2012, and one on exporting database scripts in SQL Server Management Studio 2012, as well as updates to visuals throughout the course.
Q: In the chapter on user authentication, an authentication error results when I try to use the Login component or register a new user. How do I fix this?
A: This is a known error that can occur when using the original release of Visual Studio 2012 Express for Web. Update your copy of Visual Studio for Web to at least maintenance release 1, and then try the exercise again.