Subject: Endless hours/language in Chatterblock

Posted on: 20/06/05 02:29pm

1) Chatterblock has an option called "Number of hours of Chatter history to display". What if I want it to be unlimited? Sure, I can just enter 999999999, but is there a given number for this choice, like 0? Can I just enter 0?

2) Chatterblock (and other plugins?) has english.php . My Geeklog uses english_utf-8.php and still Geeklog is smart enough to use Chatterblock's english.php . How come? And what if I also use, say, Geeklog's hebrew.php? Should I just create an internal hebrew.php for Chatterblock?


Endless hours/language in Chatterblock

Posted on: 29/06/05 01:22pm

Oh, come on...

Endless hours/language in Chatterblock

Posted on: 29/06/05 02:17pm
By: THEMike

as for 1, I don't know, ask the chatterblock author directly.

For 2.

Geeklog has a system default language, and optionaly a user language. if languages/userlanguage.php does not exist, the system falls over to languages/systemlanguage.php.

Plugins generaly use the following code;

$langfile = $_CONF['path'] . 'plugins/pluginname/language/' . $_CONF['language'] . '.php';
if (file_exists ($langfile)) {
    require_once ($langfile);
} else {
    require_once ($_CONF['path'] . 'plugins/pluginname/language/english.php');

So if the plugin doesn't have the language chosen, then it will fail over to the english. Note that $_CONF['language'] is set intellegently in lib-common.php, it defaults to the value in config.php, but, if the user has a language set that exists, it is changed to that. SO a system configured to run in german, with a user who asks for english $_CONF will say it's english by the time this code executes, unless english.php doesn't exist when it'll stay as german. If you follow.

So if you want to run your site in hebrew, and your plugins don't have a hebrew.php then you'll have to create one or the plugin will (likely) default to english instead.

Hope that helps.

Geeklog - Forum