Revision 1156
Added by Dietmar about 15 years ago
branches/2.8.x/wb/framework/functions.php | ||
---|---|---|
776 | 776 |
// Load module into DB |
777 | 777 |
function load_module($directory, $install = false) { |
778 | 778 |
global $database,$admin,$MESSAGE; |
779 |
if(is_dir($directory) AND file_exists($directory.'/info.php'))
|
|
780 |
{
|
|
781 |
require($directory.'/info.php');
|
|
779 |
if(is_dir($directory) AND file_exists($directory.'/info.php')) |
|
780 |
{ |
|
781 |
require($directory.'/info.php'); |
|
782 | 782 |
if(isset($module_name)) |
783 | 783 |
{ |
784 | 784 |
if(!isset($module_license)) { $module_license = 'GNU General Public License'; } |
... | ... | |
810 | 810 |
// Load template into DB |
811 | 811 |
function load_template($directory) { |
812 | 812 |
global $database; |
813 |
if(file_exists($directory.'/info.php')) { |
|
813 |
if(is_dir($directory) AND file_exists($directory.'/info.php')) {
|
|
814 | 814 |
require($directory.'/info.php'); |
815 | 815 |
if(isset($template_name)) { |
816 | 816 |
if(!isset($template_license)) { $template_license = 'GNU General Public License'; } |
Also available in: Unified diff
Ticket #815 Fix Warning: open_basedir restriction in effect. File is in wrong directory in load_template