$INCLUDE and FUD API [message #187768] |
Fri, 20 September 2019 13:54 |
BugLaden
Messages: 216 Registered: February 2002 Location: Westminster, MD
Karma: 0
|
Senior Member |
|
|
I'm trying to implement some FUD API calls into my site. The first instruction the the API documentation is to include GLOBALS.php into my code.
But immediately I'm getting a
Notice (8): Undefined variable: INCLUDE [ROOT/FUDforum/include/GLOBALS.php, line 117]
I did a find -name and couldn't find where $INCLUDE is defined. Can someone point me in the right direction so I can include that file as well?
-=BugLaden
[Updated on: Fri, 20 September 2019 14:22] Report message to a moderator
|
|
|
Re: $INCLUDE and FUD API [message #187769 is a reply to message #187768] |
Fri, 20 September 2019 17:45 |
BugLaden
Messages: 216 Registered: February 2002 Location: Westminster, MD
Karma: 0
|
Senior Member |
|
|
Line 12 in GLOBALS.php is:
$GLOBALS['INCLUDE'] = '/home2/bugladen/cake/tobacconerd/FUDforum/include/';
but line 117 is
require($INCLUDE .'core.inc');
It seems like 117 should be changed to
require($GLOBALS['INCLUDE'] .'core.inc');
and this gets rid of the error I reported in the OP.
There are two other instances of $INCLUDE found using grep
./include/glob.inc: $stripped_globals = str_replace('require($INCLUDE .\'core.inc\');', '', $globals);
./src/post.php.t: $data = file_get_contents($INCLUDE .'theme/'. $usr->theme_name .'/usercp.inc');
-=BugLaden
|
|
|
|
|