/*************************
  Coppermine Photo Gallery
  ************************
  Copyright (c) 2003-2005 Coppermine Dev Team
  v1.1 originally written by Gregory DEMAR

  This program is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 2 of the License, or
  (at your option) any later version.
  ********************************************
  Coppermine version: 1.4.3
  $Source$
  $Revision: 1.2 $
  $Author: Nibbler $
  $Date: 2006-01-17 $
**********************************************/

What it does:
-------------
Displays number and identity of users currently browsing the gallery.
This plugin has been created for cpg1.4.x

=========================================================================

How to install:
---------------
* Log into your coppermine page as admin
* Go to coppermine's config, expand "General settings", click "Manage plugins" next to "Enable plugins" (make sure that you have set "Enable plugins to "Yes"). Alternatively, you can directly access the plugin manager by entering http://yoursite.tld/your_coppermine_folder/pluginmgr.php into the address bar of your browser
* On the plugin manager page, click "browse", navigate to the plugin zip, click "upload". Alternatively, you can unzip the plugin on your client (preserving the folder structure) and then FTP-upload the unzipped folder into the plugins sub-folder of your coppermine install.
* If the plugin has been unzipped properly on your server, the plugin manager should refresh and you should see the plugin listed in the section "Plugins Not installed". Click the install icon (the "i") next to it
* If the plugin has got a configuration screen, go through it and submit your changes. "Onlinestats" does have a configuration screen that prompts for the time users should be displayed as being online before dropping out of the index for inactivity. It is recommended that you keep the default value.
* Most plugins are then ready for use and active. Onlinestats has to be enabled separately, see below.

=========================================================================

How to enable:
--------------
To enable this plugin, you'll have to add "onlinestats" to "the content of the main page" in coppermine's config in the section "Album list view". The setting should look like "breadcrumb/catlist/alblist/onlinestats" or similar. For details, review the documentation that comes with coppermine (inside the docs folder) in the section "The gallery configuration page" > "Album list view" > "The content of the main page".

=========================================================================

Known issues:
-------------
The plugin currently comes in English only, there are no language files available yet. To translate it, edit codebase.php directly with a plain text editor (notepad.exe is fine).

=========================================================================

Credits:
--------
This plugin was created by Nibbler. It is based on the "Who is online mod" for cpg1.3.x.
Don't try to contact the plugin author for support - post on the board publicly instead.

=========================================================================

Caveats:
--------
This plugin is still in an early beta stage (experimental). Please report possible bugs or improvements on the thread that deals with it: http://coppermine-gallery.net/forum/index.php?topic=26532.0
The plugin runs additional queries on the database each time it is being executed, burning cpu cycles and using resources. If your coppermine gallery is slow or has got a lot of users, you shouldn't use it.

Changes:
--------
From 1.1 to 1.2
* Fixed the set duration not being taken into account

Corresponding thread: http://coppermine-gallery.net/forum/index.php?topic=26532.0