Please help me (I checked this item just now, it should be called ServerPush). The main purpose is to [control PHP] refresh itself after changing the database content, [display PHP. In the past, I used to [display PHP] to constantly refresh and retrieve a value from the database as include other files... please kindly help me (I checked this item just now, it should be called Server Push). The theme is:
[Control-side PHP] refreshes itself only after the database content is changed.
In the past, I used to [display PHP] to constantly refresh and retrieve a value from the database as the file name to include other files. In this way, I can use [control PHP] to change the database, to control the pages included in [display PHP], so as to update the [display PHP] content in real time.
The requirement is that an include page contains several seconds of animation (some pages have animations, some pages do not, therefore, you cannot solve this problem by changing the scheduled refresh time in a unified manner. Therefore, the server must send a message (that is, the value retrieved from the original database) to the [display PHP ), if the value received by the [display PHP] is different from the one just received, the value is used as the file name of the include statement. If the value is the same, you do not need to actively refresh the database (because you can control [control PHP], you can make [control PHP] modify the database after the animation is completed, to refresh the [display PHP ).
Thank you for your advice! Thanks for the complete set of simple examples!
Reply content:
Please kindly help me (I checked this item just now, it should be called Server Push). The theme is:
[Control-side PHP] refreshes itself only after the database content is changed.
In the past, I used to [display PHP] to constantly refresh and retrieve a value from the database as the file name to include other files. In this way, I can use [control PHP] to change the database, to control the pages included in [display PHP], so as to update the [display PHP] content in real time.
The requirement is that an include page contains several seconds of animation (some pages have animations, some pages do not, therefore, you cannot solve this problem by changing the scheduled refresh time in a unified manner. Therefore, the server must send a message (that is, the value retrieved from the original database) to the [display PHP ), if the value received by the [display PHP] is different from the one just received, the value is used as the file name of the include statement. If the value is the same, you do not need to actively refresh the database (because you can control [control PHP], you can make [control PHP] modify the database after the animation is completed, to refresh the [display PHP ).
Thank you for your advice! Thanks for the complete set of simple examples!
After refreshing, the page address is included in cookies or sessions. After each address is obtained, compare it with it. If it is the same, it will not move. If it is different, it will be refreshed.