PHP Classes

File: src/autoload.php

Recommend this page to a friend!
  Classes of Joubert RedRat   PHP AJAX Table   src/autoload.php   Download  
File: src/autoload.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: PHP AJAX Table
Load HTML tables dynamically using AJAX
Author: By
Last change:
Date: 7 years ago
Size: 520 bytes
 

Contents

Class file image Download
<?php
/**
 * Autoloader
 *
 * @author Joubert <eu@redrat.com.br>
 * @copyright Copyright (c) 2016 Vector Internet Business and AjaxTable contributors
 * @license: MIT
 * @see https://github.com/vectornet/ajaxtable/
 * @see http://www.vectornet.com.br
 */

namespace VectorDev\AjaxTable;

spl_autoload_register(function ($class) {
    if (
strpos($class, __NAMESPACE__.'\\') === 0) {
       
$name = substr($class, strlen(__NAMESPACE__));
        require(
__DIR__.strtr($name, '\\', DIRECTORY_SEPARATOR).'.php');
    }
});