Home Backend Development PHP Problem Is php front-end or back-end?

Is php front-end or back-end?

Sep 27, 2019 pm 04:24 PM
front end

Is php front-end or back-end?

Most network programs are in C/S mode, that is, the client and server transmit data and interact with each other. Web applications are in C/S mode, and the browser serves as a universal client, so we often use B/S to describe this mode. In the Web, the client (browser) is the front end, the server is the back end, and the front and back are relative to the programmer.

I don’t think it’s appropriate to say whether PHP is used for front-end or back-end. PHP runs on the back-end (server side), and the running results will be sent to the front-end (client, browser) for display.

Just like the editor of a newspaper office, he writes the article in the newspaper office, prints it in the newspaper, and then sends it to you for you to read. From my personal understanding, there is actually a difference between front-end in a narrow sense and front-end in a broad sense.

Everyone has already made it clear that the front end in the narrow sense is "the visible part (in the browser)". The main technologies are HTML, CSS, JavaScript, Flash, siverlight, etc.

The broad front-end includes the page output by the server to the user's browser, which is the View layer in the MVC framework. The corresponding back-end is service and data access. In the server, the front end will encapsulate part of the logic of page display. For example, when rendering a table, a loop will be made at this layer (of course it can also be rendered with js), or a form will be produced. Because it is executed on the server side, the advantage is that it is fast and safe.

Of course, the function of PHP is not limited to the output page, but also the logic layer, service layer and DAO, and perhaps reading and writing files, message queues, event mechanisms, etc. Strictly speaking, PHP does much more on the backend than on the frontend. Different companies may have different understandings of this. I think there is no need to be serious about this. Even students who work in narrow front-end work will be very beneficial to understand the PHP framework.

The above is the detailed content of Is php front-end or back-end?. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot Article Tags

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

An article about memory control in Node An article about memory control in Node Apr 26, 2023 pm 05:37 PM

An article about memory control in Node

Explore how to write unit tests in Vue3 Explore how to write unit tests in Vue3 Apr 25, 2023 pm 07:41 PM

Explore how to write unit tests in Vue3

Let's talk in depth about the File module in Node Let's talk in depth about the File module in Node Apr 24, 2023 pm 05:49 PM

Let's talk in depth about the File module in Node

PHP and Vue: a perfect pairing of front-end development tools PHP and Vue: a perfect pairing of front-end development tools Mar 16, 2024 pm 12:09 PM

PHP and Vue: a perfect pairing of front-end development tools

How to solve cross-domain issues? A brief analysis of common solutions How to solve cross-domain issues? A brief analysis of common solutions Apr 25, 2023 pm 07:57 PM

How to solve cross-domain issues? A brief analysis of common solutions

Questions frequently asked by front-end interviewers Questions frequently asked by front-end interviewers Mar 19, 2024 pm 02:24 PM

Questions frequently asked by front-end interviewers

Learn more about Buffers in Node Learn more about Buffers in Node Apr 25, 2023 pm 07:49 PM

Learn more about Buffers in Node

How to use Go language for front-end development? How to use Go language for front-end development? Jun 10, 2023 pm 05:00 PM

How to use Go language for front-end development?

See all articles