PHP:自动加载器找不到该文件


PHP: autoloader can't find the file

我正在使用自动加载器按其命名空间加载类,它在本地主机上工作正常,但在在线服务器上无法正常工作。
Autoloader.php加载类时,PHP向我显示此错误:

Warning: require('..'backoffice'controllers'EquipementsManager.php) failed to open stream: No such file or directory

但我确定路径是正确的,并且文件EquipementsManager.php存在于此路径中!这意味着自动加载器正在以正确的路径正确加载类,但 PHP 一直给我No such file or directory错误!
Autoloader.php代码 :

<?php
/**
 * Class Autoloader
 */
class Autoloader{
    /**
     * Enregistre notre autoloader
     */
    static function register(){
        spl_autoload_register(array(__CLASS__, 'autoload'));
    }
    /**
     * Inclue le fichier correspondant à notre classe
     * @param $class string Le nom de la classe à charger
     */
    static function autoload($class){
        require '''..'''.$class . '.php';
    }
}

班级装备经理:

namespace backoffice'controllers;
use backoffice'entities'Connexion;
use backoffice'entities'Equipement;
class EquipementsManager{
    //---some stuff to do----
}

我也尝试了这个__DIR__.'''..'''.$class . '.php'仍然是同样的问题,适用于本地主机但不适用于在线。
今天编辑(20/02/2016):
我将我的 autoload() 函数编辑为:

static function autoload($class){
        $file = (strpos($class, 'backoffice') === false) ? $class : str_replace('''', DIRECTORY_SEPARATOR, $class);
        require $file . '.php';
    }

现在我的文件已正确加载,但出现另一个错误:

require(JsonSerializable.php) [function.require]: failed to open stream: No such file or directory

我使用 'JsonSerializable interface 将我的 objet 转换为 jason 数组,如下所示:

namespace backoffice'entities;
/**
 * PropertyType
 */
class PropertyType implements 'JsonSerializable
{
}

如你所知,这个接口在SPL中,为什么他不知道呢?!

尝试

$require = str_replace('''', DIRECTORY_SEPARATOR, '..'''.$class.'.php');
require($require);