From a88e61ca1ed1fa1ff145aa1feae10e9529b778bd Mon Sep 17 00:00:00 2001 From: Marien Fressinaud Date: Wed, 10 Apr 2013 21:35:10 +0200 Subject: Màj de la librairie SimplePie, fix bug #48 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/SimplePie_autoloader.php | 86 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 lib/SimplePie_autoloader.php (limited to 'lib/SimplePie_autoloader.php') diff --git a/lib/SimplePie_autoloader.php b/lib/SimplePie_autoloader.php new file mode 100644 index 000000000..3f67635b0 --- /dev/null +++ b/lib/SimplePie_autoloader.php @@ -0,0 +1,86 @@ +path = dirname(__FILE__) . DIRECTORY_SEPARATOR . 'SimplePie'; + } + + /** + * Autoloader + * + * @param string $class The name of the class to attempt to load. + */ + public function autoload($class) + { + // Only load the class if it starts with "SimplePie" + if (strpos($class, 'SimplePie') !== 0) + { + return; + } + + $filename = $this->path . DIRECTORY_SEPARATOR . str_replace('_', DIRECTORY_SEPARATOR, $class) . '.php'; + include $filename; + } +} -- cgit v1.2.3