mirror of
https://github.com/predis/predis.git
synced 2026-09-11 19:07:30 +00:00
Register an autoloader function for examples.
This commit is contained in:
@@ -1,5 +1,11 @@
|
||||
<?php
|
||||
require_once '../lib/Predis.php';
|
||||
spl_autoload_register(function($class) {
|
||||
$file = __DIR__.'/../lib/'.strtr($class, '\\', '/').'.php';
|
||||
if (file_exists($file)) {
|
||||
require $file;
|
||||
return true;
|
||||
}
|
||||
});
|
||||
|
||||
$single_server = array(
|
||||
'host' => '127.0.0.1',
|
||||
|
||||
Reference in New Issue
Block a user