Jump to content

Error with an imageboard: "Warning: Creating default object from empty value in"


usermane

Recommended Posts

I installed an imageboard (kusaba x) and while i can navigate and make changes in the administrator account i get this message left and right in the screen:

 

"Warning: Creating default object from empty value in /home/username/public_html/lib/gettext/gettext.inc.php on line 154"

 

I checked the file and line 154 is:

$text_domains[$domain]->path = $path;

 

Am posting this on coding section because i assume i must change something in the code.

Will appreciate any kind of help.

That will happen if $text_domains[$domain] is not set or is null.

 

Looking at trunk I don't see that code. Where did you get yours from?

 

http://sourceforge.net/projects/kusabax/files/Kusaba%20X%20v0.8/Kusaba%20X%20v0.8%20Full/

 

But it seems i downloaded v08 instead of v09.

Will look at the specific file for the difference.

It's probably for the better. The v0.8 file has the offending function

/**
 * Sets the path for a domain.
 */
function _bindtextdomain($domain, $path) {
global $text_domains;
// ensure $path ends with a slash
if ($path[strlen($path) - 1] != '/') $path .= '/';
elseif ($path[strlen($path) - 1] != '\\') $path .= '\\';
$text_domains[$domain]->path = $path;
}

but the same problem shows up in other functions too. It seems like it's just bad coding at fault and fixing that could be a bother.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.