路径方式,代码如下:

define('BASE_PATH',str_replace('\\','/',realpath(dirname(__FILE__).'/'))."/"); 
 
echo BASE_PATH; 
//输出结果:D:\AppServ\www\7.11 

 

相关文章: