先來說說兩種方式:
1)定義一個字串變量,裡面儲存要載入的檔案清單。然後foreach加載。
複製程式碼 程式碼如下:
$a = '/a.class.php;/Util/b.class. php;/Util/c.class.php';
$b = '/d.php;/e.class.php;/f.class.php;/g.class.php';
/ / 載入基本系統檔案
$kernel_require_files = explode(';', $a);//SYS_REQUIRE_LIB_FILE_LIST);
foreach($kernel_require_files as $f){
$f);
}
// 載入基本系統檔案
$kernel_require_files = explode(';', $b);//SYS_BASE_FILE_LIST);
foreach($kernel_require_files as $f){
require_once(KERNEL_PATH.$f);
}
複製程式碼 程式碼如下:
require_once('func.php'); 🎜>require_once('LangManager.class.php');
require_once('_KernelAutoLoader.class.php');
require_once('ApplicationSettingManager.class.php');
require_once('ApplicationSettingManager.class.php');
require_once('ApplicationSettingManager.class.php');
require_once' /Activator.class.php');
require_once('lib/System/Util/CXML.class.php');
require_once('lib/System/Util/CWeb.class.php');