How web applications work

dusty candland | Tue Dec 14 2010 | applications and frameworks, web applications

Web applications are a client/server-based model.

"Huh?" you ask.

The client is your Web browser -- think Safari, Firefox or Internet Explorer -- and the server is the computer that allows you to see, or "serves," the Web application. There are many technologies that make Web applications work, but there are a few primary ones that we'll mention here. The basic technologies are Hyper Text Markup Language (HTML), Cascading Style Sheets (CSS) and JavaScript (JS). These make up the majority of the websites on the Internet. Some secondary technologies are Flash and Silverlight, which mostly are used for video, animation and games. On the backend, there are programming languages, such as Ruby, Python, PHP, Java, and .Net.

Let's look at how these things work together.


When you request -- or want to visit -- a Web page, an HTML document or file is sent from that page's server down to your computer. Many times, that HTML document or file is going to be produced when you requested it thanks to a programming language on the server.

That HTML is probably going to contain CSS, which is used to make the Web page you want to visit look nice. CSS makes it easier to change the look of the HTML document for tasks such as printing and mobile phone display.

JavaScript will also mostly likely be a part of that HTML document. JavaScript is a programming language that runs in your Web browser and interacts with the HTML page. It can change, animate and interact with any part of the HTML document without going back to the server. It can also call back to the server to get more data or call other functions onto the server. This is called AJAX, and it is used on a growing number of sites. If you use a Web-based email client, it's probably using AJAX. AJAX makes for a better user experience by allowing faster, behind-the-scenes interactions with the server.

When you click a button or fill out a form on the Web page you've visited, the data you've provided are sent back to the server and complete some interaction with the Web application.

One key thing to know about Web applications is that they are stateless -- meaning they don't know one user from the next. What allows Web applications to identify individual users are known as cookies, which are bits of data that your browser sends to a server every time you request to visit a Web page. Cookies are limited by the domain name of the Web application, so cookies for are not sent to anyone other than Without cookies, Web applications would not effectively be able to know you from anyone else accessing the application. Your click or form data are then processed on the server by one the programming languages, which, in turn, updates data in a database.

Now that you have an idea about how web applications work, you'll need to give some thought to the technologies you use to have your application built. Some are chosen for you -- and you can count on HTML, CSS and JavaScript being a part of your application no matter what. However, other technologies -- including the server, the programming language and the database you choose -- can have a large effect on your web application. Contact Red27 for help selecting what is right for your company or specific project.