final public static function autoload($class)
    {
        if (version_compare(PHP_VERSION, '5.3', '>=') && __NAMESPACE__) {
            $class = str_replace(__NAMESPACE__, 'PHPTAL', $class);
            $class = strtr($class, '\\', '_');
        }

        if (substr($class, 0, 7) !== 'PHPTAL_') return;

        $path = dirname(__FILE__) . strtr("_".$class, "_", DIRECTORY_SEPARATOR) . '.php';

        require $path;
    }
final public static function autoload($class)
    {
        if (version_compare(PHP_VERSION, '5.3', '>=') && __NAMESPACE__) {
            $class = str_replace(__NAMESPACE__, 'PHPTAL', $class);
            $class = strtr($class, '\\', '_');
        }

        if (substr($class, 0, 7) !== 'PHPTAL_') return;

        $path = dirname(__FILE__) . strtr("_".$class, "_", DIRECTORY_SEPARATOR) . '.php';

        require $path;
    }
final public static function autoload ( $ class ) { if ( version_compare ( PHP_VERSION , '5.3' , '>=' ) && __NAMESPACE__ ) { $ class = str_replace ( __NAMESPACE__ , 'PHPTAL' , $ class ) ; $ class = strtr ( $ class , '\\' , '_' ) ; } if ( substr ( $ class , 0 , 7 ) !== 'PHPTAL_' ) return ; $ path = dirname ( __FILE__ ) . strtr ( "_" . $ class , "_" , DIRECTORY_SEPARATOR ) . '.php' ; require $ path ; }
Suitable for callbacks from SPL autoload

@param string $class class name to load

@return void
Suitable for callbacks from SPL autoload