For a Web Developer, or a Someone Running a Website in General it is Important to understand the difference between Client side processes and Server Side processes. I have been getting alot of questions asked about things from both Developers and Clients who do not understand the difference so I figured I would write a short article explaining the difference.
Web pages are displayed in your browser on your local machine. Just like a customer or client for a restaurant, you and your browser are a client using a Web site. The Web site is displayed by your browser, which interprets code that was sent to it. In general this code will be primarily HTML, but may also contain anything supported by your browser such as javascript, flash movies, and more.
The machine where the Web site actually resides is called a Web server. When you send a request for a Web page by entering a Web site address, this request is sent to a Web Server. The Web server then sends the Web page to your browser. The interesting thing about a Web server is that it can manipulate the code within a Web page before sending it to your browser. For most Web pages, no manipulation is done. Rather, the server simply sends a copy to the browser and the browser does the work of displaying the code.
A Web Server can manipulate what is included in a Web page before sending it. When the request is made to a server to send a Web page, the server can actually execute a program instead. This can be a program written in a variety of languages. Some of the programming languages and technologies that can be used are Active Server Pages (ASP), PHP, C/C++, and Ruby, Java Server Pages (JSP), and more. Of course, in order to use any of these languages, the server must support them.
An important issue when working with Web applications is to remember that the Web server is separate from the Web browsers that will use a Web site’s pages. The Web server can be located anywhere in the world — or even off the world! The browser is generally on a machine you are using. Stated a different way, you can act as a customer, or client, using a browser to access a Web site that is located on a Web server.
The programs running on the Web Server are server side programs because they are on the side of the internet that the Web server is on. The browser being used to access the Web site is on the same side of the Web as you, the client side. If code is executed on the Web server, it is considered server side code. If code is executed on your browser, it is considered client-side. Because the internet is vast, the client side and server side programs are not constantly in contact with each other. Because of this, there is code that you can use on the server and there is code that you can use on the client.
What do you do on the server?
There are a number of types of programming things that can be done on the server. One of the primary functions you can do with code is to prepare the code that is to be sent to the Web browser. This includes such tasks as building pages customized for the type of browser that requested a page. It could also include doing tapping into a database to create information for a Web page. A very popular server side program is a Visitor Counter that keeps track of the number of people who have accessed a Web Site. The counter program would keep track of people who have come and store the information. It would also provide the actual number for any Web pages that are sent back to a browser.
What do you do on the client?
HTML, javascript, Flash files, ActiveX controls, Java applets, and a number of other technologies can be executed on the client side. You can execute any technology supported by your browser. Client side programming is used because the browser is separate from the server. By including code within a web page, a number of features can be added to a Web page without the need to send information to the Web Server which takes time. Tasks done on the client side include data validation, special formatting features that go beyond HTML, controls that take care of page navigation and ad presentation, and more.
Email Clients
This is the important part now that you have a basic understanding of the fundamentals of how the Web Works, let’s talk about what exactly a Client side Application is.
First a Client side application is a Program Written in a language and compiled to work on your Operating System, for example Outlook, Internet Explorer, Firefox, Thunderbird, etc, etc.
A client side application can not change what a server side process does it can only interact with it in certain ways. Lets take a email client to start since that’s were I hear the confusion constantly coming from.
Your email is stored on your Server just like if you connected your Digital camera to your Home PC and stored your pictures there. Now The Server is hosted somewhere and it is built very much like a normal pc. It has all the same things a normal pc would have except to save ram and disk space they don’t have window managers since they aren’t very useful. Anyway back to the email. Your email accounts, messages, passwords, etc are stored on the Server. You would then retrieve these emails using a client such as Outlook, Evolution, Thunderbird, KMail, etc. You set these clients up with your servers Mail Port ( mail.yourserver.com ) and you add you Account name and password. It then retrieves the email and stores it on your desktop, phone, or wherever you store it.
Now the catch is you have to have the correct Settings to Access this information or it wouldn’t be secure. Now if you forget the password to your email account, or your change it, or your computer loses it because of a hard shut-down, then you will have to change this password on the Server Side through your control panel or through your web mail account. Once changed you have to change it in your Client Side application to connect.
Hopefully this helps you get a better understanding of how the internet works.
Tags: Bandwidth, provider, Web Development, Website