Home >Backend Development >PHP Tutorial >Can I send a request to update a certain page in the project in PHP?

Can I send a request to update a certain page in the project in PHP?

WBOY
WBOYOriginal
2016-07-06 13:51:21853browse

The project is in three-frame mode, top, middle, and left. The requirement is that after I execute a certain action, I will update the top header information. How to implement this?
For example: I insert a piece of data into the database in a PHP script, and then the insertion is successful and the top page is refreshed. Something like this

Reply content:

The project is in three-frame mode, top, middle, and left. The requirement is that after I execute a certain action, I will update the top header information. How to implement this?
For example: I insert a piece of data into the database in a PHP script, and then the insertion is successful and the top page is refreshed. Something like this

When performing an operation, use JS to send a request to the backend and return the data to modify the specified content

ajax or iframe

Use Websocket to connect permanently

Ajax can be implemented asynchronously. Every time the operation is successful, Ajax will go to the server to pull the top template and append it up

Statement:
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