From fe20539226a68fbcac2f362e3523a895066f37ae Mon Sep 17 00:00:00 2001 From: Marc MAURICE Date: Thu, 30 Dec 2010 10:40:38 +0100 Subject: [PATCH] Added function to include a file in all plugins --- index.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/index.php b/index.php index b2c2dde..ff50603 100644 --- a/index.php +++ b/index.php @@ -25,6 +25,12 @@ array_shift($plugins); array_shift($plugins); // remove . and .. foreach ($plugins as $p) if (is_file("plugins/$p/functions.php")) require "plugins/$p/functions.php"; +function plugins_include($phpFile) +{ + foreach ($GLOBALS['plugins'] as $p) if (is_file("plugins/$p/$phpFile")) + require "plugins/$p/$phpFile"; +} + if (! function_exists('getThumbTarget')) { function getThumbTarget($imageSimplePath) { @@ -199,6 +205,8 @@ a {
^
+ +
-- 1.7.10.4