Difference between back-end and front-end?

Asked

Viewed 1,744 times

4

Guys, there’s a home page that has 3 filters:

  • (select) Property Type: House or Apartment
  • (select) Business Type: Purchase or Rent
  • (input) City or district

The person enters with the 3 search parameters and clicks on the "search" button. Next is shown the properties to buy or rent according to the city/ neighborhood she reported.

My doubt is: The filtering of the properties through the parameters that were informed at home and that will be shown in the next screen, is front-end or back-end service?

Thanks

  • 1

    It depends a lot, where will come this data, if it is a database would be back-end even, if it is a list made in HTML, would be front, each case is a case, clarify a little more your doubt.

5 answers

7

It is probably an action performed on back-end, because filtering is usually done via SQL Query, then to perform operations in the database a language of back-end like the PHP.

However this may vary according to the developer, another case may happen, such as: having a javascript that after the selections send a Ajax to the PHP which then conducts the search, in which case the filtering is done in the front-end but the search is performed by back-end.

More can be found at these links:

Wikipedia - Back and Front End

Fábio Lobo - Difference between back and front end

Tabless - Beginners - Client and Server side

5

TL;DR - Depends.

Long version: You should take into account data traffic and user experience.

If your data volume is small (a few hundred records), simply transfer the complete collection to the client and filter locally. Running filtering in the back-end in this case is counterproductive, since you are running on the server operations that the client can perform without much effort.

If your collection is extensive you can perform the filtering, ordering and paging processes on the server and send only the content to be viewed at the moment.

4

Front-End

The front end would be the visual part of the site or system.

When we say "I will develop the site front-end" it means the same thing as "I will develop the site’s HTML, CSS and/or JS". Front-end is all that stands in front (front)

Back-End

It is the back part of the site, where all the magic happens, where the user does not see working like SQL requests, sending emails, etc. The back end (back) would be programming, for example, PHP.

In your case, the selects and the input are part of the front-end but the result that if given after clicking the button, responsible is the back-end (programming), which brought the necessary information from SQL.

Summing up your question:

The filtering of the properties through the parameters that were informed in the home and that will be shown in the next screen, is front-end or back-end service?

Answer: It’s back-end service

-1

All you need a processing behind is back-end. In that case you will have to manipulate receive, manipulate and return data.

Think front end simply as something will be displayed, styling.

However you can do it using a Java or Javascript-like back-end language that is used for both back and front-end.

-1

Front-End is the front, visual.

In the Front-End you fill out the forms with the data to be sent to the Back-End.

Back-End is the back where the data is. The Front-End sends the data to the Back-End that searches the data in the database (or other data storage location) according to the parameters passed by the Front-End and returns to the Front-End.

It is also possible that the Back-End sends all data to the Front-End that will filter according to the desired parameters, but such procedure is not recommended for large amounts of data.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.