PHP Classes
elePHPant
Icontem

File: bootstrap.php

Recommend this page to a friend!
  Classes of Alexandre Sinício  >  PHP Cloud Storage Abstraction  >  bootstrap.php  >  Download  
File: bootstrap.php
Role: Example script
Content type: text/plain
Description: Example script
Class: PHP Cloud Storage Abstraction
Store and retrieve data in multiple cloud services
Author: By
Last change:
Date: 1 year ago
Size: 338 bytes
 

Contents

Class file image Download
<?php
function loadClass($class) {
   
$filename = __DIR__.'/vendor/'.str_replace('\\', '/', $class).'.php';
    if (
file_exists($filename)) {
        require_once
$filename;
    } else {
        throw new
Exception('Critical error - class '.$class.' not found. Aborting operation. '.$_SERVER['REQUEST_URI']);
    }
}
spl_autoload_register('loadClass');