Linux puskom-ProLiant-DL385-Gen10 5.4.0-150-generic #167~18.04.1-Ubuntu SMP Wed May 24 00:51:42 UTC 2023 x86_64
/
home
/
puskom
/
mastur
/
tabs-responsive
/
//home/puskom/mastur/tabs-responsive/autoloader.php
<?php /** * Core Autoloder * * @since 3.1.0 */ spl_autoload_register(function ($class) { // project-specific namespace prefix $prefix = 'TABS_RES_PLUGINS\\'; // base directory for the namespace prefix $base_dir = wpshopmart_tabs_r_directory_path; // does the class use the namespace prefix? $len = strlen($prefix); if (strncmp($prefix, $class, $len) !== 0) { // no, move to the next registered autoloader return; } // get the relative class name $relative_class = substr($class, $len); // replace the namespace prefix with the base directory, replace namespace // separators with directory separators in the relative class name, append // with .php $file = $base_dir . str_replace('\\', '/', $relative_class) . '.php'; // if the file exists, require it if (file_exists($file)) { require $file; } });