PHP naming rules


Extract the include file with common functions. The file suffix is ​​named with .inc, indicating that it is an include file.
If there are multiple .inc files that need to contain multiple pages, please encapsulate all .inc files in one file. For specific pages, you only need to include one .inc file.
For example:

xxx_session.inc
xxx_comm..inc
xxx_setting.inc
mysql_db.inc

Encapsulate the above files in the xxx.basic.inc file in the following way

require_once(”xxx_session.inc”);
require_once(”xxx_comm.inc”);
require_once(”xxx_setting.inc”);
require_once(”mysql_db.inc”);

Note: Whether it needs to be encapsulated into a file depends on the situation. If If the functions of each inc are scattered to different pages, encapsulation is not recommended.