levo

Web Technologies

Server side and client side processing

  • 1 thing to know
  • Component 01
Start revising · £5/month

Overview

Recall questions on client-side and server-side processing, examples of each, their advantages and disadvantages, bypassing client-side validation, why both sides validate, and deciding which side should handle a task.

What you need to know

Answer each one before you reveal it.

Your recallNot started
Key term

Distinguish client-side from server-side processing.

Questions from this subtopic

Each one with the model answer underneath.

  1. 1

    Define client-side processing and server-side processing.

    Model answer

    Client-side processing is work carried out by the user's own device, in the browser, on code the server has sent to it - typically JavaScript acting on the page. Server-side processing is work carried out by the web server before the response is sent, by a program running there with access to the server's files and databases; the browser receives only the result. The distinguishing question is always where the code runs and who controls that machine.

  2. 2

    Give examples of processing that happens on each side.

    Model answer

    Client-side: giving instant feedback that a required box is empty or an entry is the wrong format, showing and hiding sections of a page, animating and updating the interface, sorting or filtering a small list already downloaded, and simple arithmetic such as updating a displayed subtotal. Server-side: authenticating a login, querying or updating a database, processing a payment, sending an email, generating a page from stored data, resizing and storing an uploaded file, and re-validating everything the form submitted before storing it.

  3. 3

    What are the advantages of processing on the client?

    Model answer

    It is fast to respond, because there is no round trip to the server, so the user sees the result immediately. It reduces the load on the server, which can then serve more users with the same hardware. It reduces bandwidth, because only small amounts of data cross the network rather than a whole new page for every interaction. It works on data the user has already got, and can keep working when a small interaction would otherwise be impossible. And it makes the interface feel continuous rather than a series of page reloads.

  4. 4

    What are the disadvantages of processing on the client?

    Model answer

    The user controls the machine, so the code can be read, altered, disabled or replaced, and its results can never be trusted. Behaviour varies with the browser, its version and any extensions, so it must be tested widely. Performance depends on the user's device, so heavy processing is slow on a weak phone and drains its battery. The code and any data it uses must be downloaded first, which costs time on the initial load. And it has no access to central data, because the databases are on the server.

  5. 5

    What are the advantages of processing on the server?

    Model answer

    It is under the site owner's control, so the code cannot be seen or altered by the user and its results can be trusted - which is what makes it the only place security decisions can be made. It has direct access to the databases and files that hold the site's data. It behaves identically for every user regardless of their browser or device, so there is nothing to test across platforms and low-powered devices are not disadvantaged. It can use as much processing power as the server has, so heavy work is feasible. And a change to the code takes effect for everyone immediately, with nothing to download.

  6. 6

    What are the disadvantages of processing on the server?

    Model answer

    Every interaction needs a round trip over the network, so there is a delay before the user sees anything and the site feels less responsive, badly so on a slow or high-latency connection. All the work concentrates on one machine, so the server must be powerful enough for peak demand and can become a bottleneck or fail under load. It costs bandwidth, since data must travel both ways for each interaction. And it cannot do anything at all if the connection is lost.

Other ways to work this

The same content, four other ways.

Everything in your subscription

Runs, plus a mode for every other kind of session.

1Flash
2Imposter
3Fade
4Brain dump

Learn every subtopic in runs of four questions

Facts flash and fade, a wrong word hides in some of them, and a brain dump decides which questions are locked in.

Processors: Structure, Performance and Types
Input, Output and Storage
Systems Software
Applications Generation

Cram the night before, weakest topic first

A quick scan finds your weakest topics. Recall each fact you missed three times in a row.

If it matches, the search .
succeedsfailsrestarts

Blank Blitz consolidates the facts

Rapid timed gap-fills on the terms and numbers you need to recall without thinking.

✓What it iscovered
~Why it happenspartly there
How long it lastsnot there yet

Explain It tests your understanding

Explain a concept in your own words and see which of its points you covered.

A global variable means a variable reachable from anywhere in the program.
TrueFalse

Test It catches misconceptions

Spot the fault in a statement. The faults are the mistakes students make most often.

721941163128510

Brain Breaks between sessions

Short focus games to reset attention, so the next set lands better than the last.

Every question in Web Technologies, on a schedule.

Learn it in runs of four questions, each ending on a brain dump against the clock. Every question you lock in comes back the next day, then at longer gaps, each time just before you would forget it.

Or £46 a year, about £3.83 a month. Cancel anytime.