HTMLPurifierExtras.autoload.php 716 B

123456789101112131415161718192021222324
  1. <?php
  2. /**
  3. * @file
  4. * Convenience file that registers autoload handler for HTML Purifier.
  5. *
  6. * @warning
  7. * This autoloader does not contain the compatibility code seen in
  8. * HTMLPurifier_Bootstrap; the user is expected to make any necessary
  9. * changes to use this library.
  10. */
  11. if (function_exists('spl_autoload_register')) {
  12. spl_autoload_register(array('HTMLPurifierExtras', 'autoload'));
  13. if (function_exists('__autoload')) {
  14. // Be polite and ensure that userland autoload gets retained
  15. spl_autoload_register('__autoload');
  16. }
  17. } elseif (!function_exists('__autoload')) {
  18. require dirname(__FILE__) . '/HTMLPurifierExtras.autoload-legacy.php';
  19. }
  20. // vim: et sw=4 sts=4