Page MenuHomePhabricator

smwgIP is hard coded for the $IP . '/extensions' directory
Closed, ResolvedPublic

Description

Author: dan.bolser

Description:
I'm trying to use SF from a location other than the default "$IP/extensions" directory (for details see bug 21832). After changing include_only in LocalSettings.php appropriately, I get the following error:

[Sun Dec 13 08:45:21 2009] [error] [client 77.103.200.41] PHP Warning: require_once(/BiO/Serve/Httpd/Funktopia.net/MW-1.15/extensions/SemanticForms/languages/SF_Language.php) [<a href='function.require-once'>function.require-once</a>]: failed to open stream: No such file or directory in /BiO/Serve/Httpd/Funktopia.net/MWExtensions/SemanticForms/includes/SF_GlobalFunctions.php on line 93, referer: http://funktopia.net/index.php?title=Form:FilmReview&action=delete

[Sun Dec 13 08:45:21 2009] [error] [client 77.103.200.41] PHP Fatal error: require_once() [<a href='function.require'>function.require</a>]: Failed opening required '/BiO/Serve/Httpd/Funktopia.net/MW-1.15/extensions/SemanticForms/languages/SF_Language.php' (include_path='/BiO/Serve/Httpd/Funktopia.net/MW-1.15:/BiO/Serve/Httpd/Funktopia.net/MW-1.15/includes:/BiO/Serve/Httpd/Funktopia.net/MW-1.15/languages:.:/usr/share/pear:/usr/share/php') in /BiO/Serve/Httpd/Funktopia.net/MWExtensions/SemanticForms/includes/SF_GlobalFunctions.php on line 93, referer: http://funktopia.net/index.php?title=Form:FilmReview&action=delete

Line 93 of "SemanticForms/includes/SF_GlobalFunctions.php" looks like this:

require_once($sfgIP . '/languages/SF_Language.php');

and $sfgIP is set on line 20 of "SemanticForms/includes/SF_Settings.php":

$sfgIP = $IP . '/extensions/SemanticForms';

I changed that line to read:

$sfgIP = dirname(__FILE__) . '/..';

and it seems to have fixed the problem (but there may be other 'issues').

Since SF requires SMW, how come you can't use settings like smwgIP?

Is there a problem with the fix that I'm using?

Cheers,
Dan.


Version: unspecified
Severity: major

Details

Reference
bz21833

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 10:51 PM
bzimport set Reference to bz21833.

dan.bolser wrote:

Similar bug in SD also...

#$sdgIP = $IP . '/extensions/SemanticDrilldown';
$sdgIP = dirname(FILE) . '/..';