Delete asserts, fixes #97.
[htmlpurifier/darkodev.git] / extras / HTMLPurifierExtras.php
blob35c2ca7e72c052bd116677a7a3111e099afaefb0
1 <?php
3 /**
4 * Meta-class for HTML Purifier's extra class hierarchies, similar to
5 * HTMLPurifier_Bootstrap.
6 */
7 class HTMLPurifierExtras
10 public static function autoload($class)
12 $path = HTMLPurifierExtras::getPath($class);
13 if (!$path) return false;
14 require $path;
15 return true;
18 public static function getPath($class)
20 if (
21 strncmp('FSTools', $class, 7) !== 0 &&
22 strncmp('ConfigDoc', $class, 9) !== 0
23 ) return false;
24 // Custom implementations can go here
25 // Standard implementation:
26 return str_replace('_', '/', $class) . '.php';
31 // vim: et sw=4 sts=4