﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc	mlocked
7997	open_basedir error due to module loading bug	christian.bachert@…	Rob Smith	"Hi,

I already saw the 2 similar bugs that won't get fixed, but I believe that the code is still faulty. Have a look at the thrown message:
""Warning at /srv/http/mythweb/classes/Modules.php, line 30:
file_exists(): open_basedir restriction in effect.
'''File(./modules/welcome.php/init.php)''' is not within the allowed path(s): (/srv/http)

In fact, the file ./modules/welcome.php/init.php is nonexistent.
Modules.php makes a list of files in the modules directory, assumes they are subdirectories and tries to load init.php in each of the directories.
welcome.php isn't a directory, hence you shouldn't treat it as one.

Here's a cheap fix:
In includes/utils.php is a function called get_sorted_files. Replace

if ($file == '.' || $file == '..') continue;
with
if ($file == '.' || $file == '..' || $file == 'welcome.php') continue;

Probably there's someone that can do a lot better than this, but this did it for me."	defect	closed	minor	unknown	Plugin - MythWeb	unknown	medium	fixed	open_basedir open basedir modules		0
