If you know a little HTML, you can create a functional Web page that informs and entertains site visitors. Basic Web pages can be useful, but it takes programming code to make advanced sites that are interactive, data-driven and more compelling. The type of programming language you use depends on your Web design goals. Before you build a website, learn the differences between client-side and server-side programming. They share some features, but they differ in significant ways.
When you type a URL in your browser's address bar, your computer acts as a client that requests information from a remote Web server. All code, files, data and images that you see on Web pages come from remote servers that send it to browsers. A browser assembles resources it receives and generates the Web page you see. Simple Web pages may only contain HTML statements, text and images, while more complex ones can execute code that resides in the client browser or on the Web server.
Video of the Day
Client-Side Programming Basics
Additional Client-Side Benefits
Because the browser doesn't have to communicate with a remote Web server to perform these types of tasks, client-side code can perform some tasks faster than server-side code. For instance, when you click a button to open a menu, client-side code can run it immediately. If server-side code handled that task, you'd have to wait for the browser to communicate with the server before seeing the menu open. You also don't have to install special software on a Web server to create and test client-side code since all browsers can run client-side code.
Server-side technologies include PHP and Microsoft's ASP.NET. Server-side code runs on a site's Web server instead of in a site visitor's browser. If you visit a Web page that uses server-side programming, you may never know that the server is busy executing instructions while you view the Web page. A good example of server-side processing is an ASP.NET page that allow you to resize an image. After you click a button to upload an image to a Web server, code on the server resizes the image and sends the new image back to your browser.
Additional Server-Side Benefits
Server-side programming also gives you the ability to store and retrieve data. This is important when you wish to perform tasks such as storing and retrieving login information and giving people the ability to look up data stored in a database. That data can reside in locations such as a database or an XML file on your Web server. Server-side processing can also help you keep proprietary code confidential. For example, you could write PHP code that performs calculations using proprietary sales formulas your company keeps secret. Because the code runs on your server, people who view your Web pages in a browser cannot view that code.
Hybrid Web Applications