eli5: How does a web app work?

658 views

eli5: How does a web app work?

In: Technology

2 Answers

Anonymous 0 Comments

Hard question considering the level of complexity an answer can reach, but I’ll give it a shot.

A web application is composed by different pieces which work together to provide the user with a (or more) functionality which use dynamic data.

The main pieces composing a web application are:

Database: its where all the data is stored. Let’s take for the example your book shelves.

Data: what it’s stored in the database. The books in our example.

Backend: it’s the hidden logic which allow us to get data from the database. For our example we will imagine a friend always listening to our requests. Now, if we ask him to get a (or all) book, he will provide us what we asked for, and can tell us that he has no clue about what we just asked(if we ask for all the dog for example) , or also act strangely if we ask things in a messy way (if we ask all the books whose title has 0/0 characters)

Frontend: it’s a visual layer which provides a simple way to communicate with the backend, and can also manipulate data received to display it in a simple format. For our example, we could imagine that we want to know the published date of all books for a certain author. Unfortunately our friend (in this case) is only able give us all the book of a certain author with the related information but doesn’t know how to sort them, so we decide to ask our sister (front-end) to draw a charts using the books information, and we can easily read the data in a better way.

Few note:
1) in a web application we usually communicate with the front-end (our sister) and she takes care of the communication with the backend (our friend).

2) the backend can be extended with new functionality (for example could be able to get us the oldest book, or even to sort the book, or all the pages containing the word ELI5

3) the front-end usually provide us quick way to ask for things. (imagine you have a red buzzer on your desk that when pressed inform your sister that you need the last book published)

This should give you (more or less) the idea of how a web app works.

Anonymous 0 Comments

Well this is really broad question. But there are 2 sides of web app, frontend and backend. The frontend is the stuff that gets loaded in your browser. JavaScript can add a bit more functionality like switching between pages on button click etc… Then there is backend which runs on the server side and it communicates with the frontend, it’s most common task is to access database.

Here I’ll give you example how a certain app that you have to log in might work.
You enter it’s address in the browser. The server gets request and sends you the main page. Then you enter your account information and click the log in button.
Your information gets sent to the server, it looks for your username in the database, when it finds it, it compares the hashed password to the stored password. If the password matches than it sends a respond back to your browser letting you access your account or something.

That’s probably the most simple explanation I could give.