Server and client side processing
Introduction
When you look at a web page, you are connected to the Internet and getting back pages from the server. Many web pages hold information that is fixed or 'static' that you can read. However, there are ways of adding 'dynamic' information, information that changes, to a web page or information that personalises the web page or adds interactivity. If done in moderation and with a clear set of aims, this can add to a visitor's experience. You can achieve this in a number of ways using 'scripts'. A script is a little bit of code that is inserted into a web page to make it dynamic. You can either be done on the server, before the web page is sent (called 'server-side scripting') or be done in a viewer's web browser (called 'client-side scripting').
Server-side scripting
Server-side scripting is where the scripts are held on a server. When someone requests a web page, the scripts run, decide what needs to be displayed, generates the html pages including any adjustments as a result of the scripting and then sends them to the browser. All of the processing is done on the server and any data needed is held on the server in a database. This makes server-side processing very secure and fast as the viewer only gets the data that is actually needed at that time. Server-side scripting means that a client's web browser doesn't have to do any processing. If the client's computer is not so powerful, or they are running a laptop or phone that is perhaps a bit old, then server-side processing can certainly improve someone's web browsing experience.
It does mean that the server has to do the processing, however, which can put a strain on the server if it is having to run lots of scripts, especially if your website is hosted on a server along with thousands of other websites (a 'shared hosting' package). There are also security issues with running scripts on servers so Internet Service Providers (ISPs) tend to restrict or ban people from running scripts on any web space they give them. To take full advantage of server-side scripting, you usually need to buy a subscription to a dedicated server package to host your website.
There are a many server-side scripting languages you can use, including Perl, ASP and PHP and you can set up any of these on a desktop computer by setting up a 'pretend' server. You can find details of how to do this in any of the countless tutorials on Perl, ASP and PHP.
Perl tutorials and YouTube tutorials on Perl
ASP tutorials and YouTube tutorials on ASP
PHP tutorials and YouTube tutorials on PHP
Client-side scripting
As many web hosting packages have restrictions on running server-side scripts, website designers have to use client-side scripts instead. The browser is the client, executes the scripts and then displays whatever needs to be displayed. The most commonly used language to run client-side scripts is JavaScript. To run JavaScript, a piece of code identifying JavaScript is inserted into the HTML code for a web page along with the JavaScript code and can be used for such things as displaying dialogue boxes and accepting user input, animating pictures, adjusting how pages will look, redirections, changing pictures and so on.
You can see an example of JavaScript code and its effects from the www.w3schools.com website here:
There are many excellent tutorials available on JavaScript and if you already have a website, you will be up and running in no time. Try these or search for 'JavaScript tutorials':
http://www.w3schools.com/js/js_intro.asp
http://www.echoecho.com/javascript0.htm
http://www.lissaexplains.com/javascript.shtml
https://www.youtube.com/results?search_query=JavaScript+tutorials