相關關鍵詞
關于我們
最新文章
PHP判斷文件是否被引入的方法get_included_files用法示例
本文實例講述了PHP判斷文件是否被引入的方法get_included_files用法。分享給大家供大家參考,具體如下:
<?php // 本文件是 abc.php include 'test1.php'; include_once 'test2.php'; require 'test3.php'; require_once 'test4.php'; $included_files = get_included_files(); foreach ($included_files as $filename) { echo "$filename\n"; } ?>