//定数 Path
define("_INDEX_PATH", dirname(__FILE__)."/../");
define("_INDEX_LIB", dirname(__FILE__)."/");
define("_INDEX_LIB_CORE", _INDEX_LIB. "lib_core/");
define("_INDEX_LIB_HELPER", _INDEX_LIB. "lib_helper/");
define("_INDEX_LIB_CONF", _INDEX_PATH. "config/");
define("_INDEX_LOG_DATA", _INDEX_PATH. "log_data/");
//エラーログ用定数
define("_ERROR_LOG", _INDEX_LOG_DATA . "errlog".date("Y").".txt"); // エラーログファイル
define("_LOOP_ERROR_LOG", _INDEX_LOG_DATA . "loop_errlog.txt"); // エラーログファイル ループしたとき用
include_once(_INDEX_LIB_CONF."config.php"); // 初期設定
include_once(_INDEX_LIB_CORE."basics.php"); // サイト全体共有設定・ライブラリ
include_once(_INDEX_LIB_CORE."classObject.php"); // 最上位クラス
include_once(_INDEX_LIB_CORE."lib_error.php"); // エラー出力
include_once(_INDEX_LIB."lib_user/lib_img.php"); // 画像処理
//debug用
if(defined("_bl_debug_on") and _bl_debug_on ==true){
include_once(_INDEX_LIB_CORE."debug/phpBugLost.php"); // デバックライブラリ phpBugLost.0.3
}
//*************************************************************
// 注意)「__autoload」はphp5以上で使えます。
//
/*
function __autoload($className) {
//libフォルダ判定
$libPath = _INDEX_LIB_CORE;
if(substr_count($className,"Helper") > 0){
$libPath = _INDEX_LIB_HELPER;
}
$fileName = $className.".php";
if(is_file($libPath.$fileName)){
include_once($libPath.$fileName);
}else{
if(defined("_INDEX_LIB_USER")){
$libPath = _INDEX_LIB_USER;
}elseif(defined("_INDEX_LIB_MANAGE")){
$libPath = _INDEX_LIB_MANAGE;
}
if(is_file($libPath.$fileName)){
include_once($libPath.$fileName);
}
}
}//END function
*/
//__autoloadが非推奨になった為、下記に変更
spl_autoload_register(function ($className) {
//libフォルダ判定
$libPath = _INDEX_LIB_CORE;
if(substr_count($className,"Helper") > 0){
$libPath = _INDEX_LIB_HELPER;
}
$fileName = $className.".php";
if(is_file($libPath.$fileName)){
include_once($libPath.$fileName);
}else{
if(defined("_INDEX_LIB_USER")){
$libPath = _INDEX_LIB_USER;
}elseif(defined("_INDEX_LIB_MANAGE")){
$libPath = _INDEX_LIB_MANAGE;
}
if(is_file($libPath.$fileName)){
include_once($libPath.$fileName);
}
}
});
?>
Fatal error: Uncaught Error: Class "classTextHelper" not found in /home/c1029692/public_html/ms-energy.co.jp/coating/contact/index.php:46
Stack trace:
#0 {main}
thrown in /home/c1029692/public_html/ms-energy.co.jp/coating/contact/index.php on line 46