PATH:
home
/
lab2454c
/
archswipe.com
/
wp-content
/
plugins
/
user-registration-advanced-fields
/
includes
<?php /** * UserRegistrationAdvancedFields Autoloader. * * @class URAF_Autoloader * @version 1.0.0 * @package UserRegistrationAdvancedFields/Classes * @category Class * @author WPEverest */ if ( ! defined( 'ABSPATH' ) ) { exit; } /** * URAF_Autoloader Class */ class URAF_Autoloader { /** * Path to the includes directory. * * @var string */ private $include_path = ''; /** * Class Constructor Method. */ public function __construct() { if ( function_exists( '__autoload' ) ) { spl_autoload_register( '__autoload' ); } spl_autoload_register( array( $this, 'autoload' ) ); $this->include_path = URAF_ABSPATH . '/includes/'; } /** * Take a class name and turn it into a file name. * * @param string $class Class. * * @return string */ private function get_file_name_from_class( $class ) { return 'class-' . str_replace( '_', '-', $class ) . '.php'; } /** * Include a class file. * * @param string $path Path. * * @return bool successful or not */ private function load_file( $path ) { if ( $path && is_readable( $path ) ) { include_once $path; return true; } return false; } /** * Auto-load UR classes on demand to reduce memory consumption. * * @param string $class Class. */ public function autoload( $class ) { $class = strtolower( $class ); $file = $this->get_file_name_from_class( $class ); $path = ''; if ( strpos( $class, 'uraf_admin' ) === 0 ) { $path = $this->include_path . 'admin/'; } elseif ( strpos( $class, 'ur_form_field_' ) === 0 ) { $path = $this->include_path . 'form/'; } if ( empty( $path ) || ( ! $this->load_file( $path . $file ) && strpos( $class, 'uraf_' ) === 0 ) ) { $this->load_file( $this->include_path . $file ); } } } new URAF_Autoloader();
[+]
admin
[+]
..
[-] class-uraf-frontend.php
[edit]
[-] functions-uraf-core.php
[edit]
[-] class-uraf-ajax.php
[edit]
[-] class-uraf-autoloader.php
[edit]
[-] .htaccess
[edit]
[-] class-uraf-install.php
[edit]
[+]
form