For example, the PHP file {code...} has a problem. How to upload this $ a to another html file. The position of $ a in the following p tag shows {code...} for example:
Php file
// Read database information $ SQL = "select * from message order by id desc"; $ query = mysql_query ($ SQL ); // capture a value in the array and save it to $ a $ row = mysql_fetch_array ($ query); $ a = $ row [1];
Now the problem is coming. How to upload this $ a to another html file. The position of $ a in the following p tag is displayed:
$ A value: $
Reply content:
For example:
Php file
// Read database information $ SQL = "select * from message order by id desc"; $ query = mysql_query ($ SQL ); // capture a value in the array and save it to $ a $ row = mysql_fetch_array ($ query); $ a = $ row [1];
Now the problem is coming. How to upload this $ a to another html file. The position of $ a in the following p tag is displayed:
$ A value: $
Another HTML file must be a PHP file. Directly echo the request:
require 'view.php';
View. php content:
$ A value:
Of course, you can also read the content of a pure static HTML page and directly execute this section. This is basically the case for various template engines.
You can directly write html to the PHP file. why do you want to upload it?
Zookeeper has two types of routes: server or client.
The template engine is the actual component of the server. PHP itself is a template engine, so it can be realized by embedding the PHP used to fetch data into the object HTML, the premise is that you can change the HTML file to the PHP parser or directly register the file. php.
The essence of client-side scripting is ajax. Please calculate and manually present this document.
A. php:
// Read database information $ SQL = "select * from message order by id desc"; $ query = mysql_query ($ SQL ); // capture a value in the array and save it to $ a $ row = mysql_fetch_array ($ query); $ a = $ row [1];
B. php:
$ A value: