Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: 1 ... 5 6 7 8 [9] 10 11 12 13 ... 17   Go Down

Author Topic: "Who is online" plugin (onlinestats)  (Read 442641 times)

0 Members and 1 Guest are viewing this topic.

Nibbler

  • Guest
Re: "Who is online" plugin (onlinestats)
« Reply #160 on: January 25, 2007, 04:34:45 am »

Looks like there is missing code in the uninstall function. Change it to this

Code: [Select]
// Unnstall (drop?)

function online_uninstall()
{
    global $CONFIG;

    if (!isset($_POST['drop'])) return 1;

    if ($_POST['drop']) {
        cpg_db_query("DROP TABLE IF EXISTS {$CONFIG['TABLE_ONLINE']}");
        cpg_db_query("DELETE FROM {$CONFIG['TABLE_CONFIG']} WHERE name = 'mod_updates_duration'");
        cpg_db_query("DELETE FROM {$CONFIG['TABLE_CONFIG']} WHERE name = 'record_online_users'");
        cpg_db_query("DELETE FROM {$CONFIG['TABLE_CONFIG']} WHERE name = 'record_online_date'");
    }

    return true;
}
Logged

Fabrian

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 126
Re: "Who is online" plugin (onlinestats)
« Reply #161 on: January 25, 2007, 04:36:27 am »

I found the mod_updates_duration setting in the config table and deleted it.  I now get a critical error when accessing the site.... I guess this is because I didn't disable the plugin before removing that setting....what now?
Logged

Fabrian

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 126
Re: "Who is online" plugin (onlinestats)
« Reply #162 on: January 25, 2007, 05:06:45 am »

I had to restore the db from a backup and I updated the code, which seems to uninstall properly, except now it doesn't seem to capture the the time or display who's been on in the last 10 mins.  I do apologize if I'm in error here..
Logged

Fabrian

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 126
Re: "Who is online" plugin (onlinestats)
« Reply #163 on: January 25, 2007, 06:20:58 am »

Ok, I think everything is good now aside from one minor issue.  My time zone atm is -5 for EST, which right now shows 12:20AM.  Despite this, the plugin is showing 1:20AM.
Logged

Nibbler

  • Guest
Re: "Who is online" plugin (onlinestats)
« Reply #164 on: January 25, 2007, 12:28:32 pm »

That's a known bug, the timezone offset is applied twice. I will update the plugin when I get time.
Logged

Charity

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Gender: Female
  • Posts: 60
  • I LOVE AMANDA BYNES <33
    • Bynes-Source.Net
Re: "Who is online" plugin (onlinestats)
« Reply #165 on: January 25, 2007, 10:33:57 pm »

help?

someone plz help me and tell me what to do!  :(
Logged

Invalid ID

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 22
    • Apni Mehfil
Re: "Who is online" plugin (onlinestats)
« Reply #166 on: January 31, 2007, 06:12:30 pm »

Thanks a lot. It was something I wanted for months :)

I have one problem, my timing is 5+ and I have mentioned that in the Config. But the time shown in this plugin is way ahead than that.

How can I modify the time?
Logged

Nibbler

  • Guest
Re: "Who is online" plugin (onlinestats)
« Reply #167 on: January 31, 2007, 07:05:32 pm »

That's a known bug, the timezone offset is applied twice. I will update the plugin when I get time.
Logged

Master of Disaster

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 22
Re: "Who is online" plugin (onlinestats)
« Reply #168 on: February 02, 2007, 10:01:33 am »

Is it possible to code an extension of the plugin which shows where in the gallery the uses are?
In phpBB there is a link on the headline "Where is online" and the extension should perhaps be similar to this feature in phpBB.
I am very interested in such an extension!

Could anyone create this extension if it is possible?

René
Logged

SAAS

  • Translator
  • Coppermine newbie
  • **
  • Offline Offline
  • Posts: 8
Re: "Who is online" plugin (onlinestats)
« Reply #169 on: February 03, 2007, 07:12:03 pm »

i have a little problem with the language file

when i modified the english file and made a new one for my language i had a problem.

the problem is the language im using is a right to left languge when i installed the plug in it turned out left to right when i uninstalled it it went back to normal .

could you check it plz ^^
Logged

puku

  • Coppermine newbie
  • Offline Offline
  • Posts: 4
Re: "Who is online" plugin (onlinestats)
« Reply #170 on: February 14, 2007, 09:46:40 pm »

 :)  ;D perfect plugin
but I need to change it to display just these info:
"In total there is 1 user online
Most users ever online: 1 on St, Únor.14.2007 at 21:09"
nothing else
what should I change to erase the rest of info
please help
thx a lot
Logged

Nibbler

  • Guest
Re: "Who is online" plugin (onlinestats)
« Reply #171 on: February 14, 2007, 10:59:06 pm »

Look through codebase.php and comment out/delete anything you don't want.
Logged

puku

  • Coppermine newbie
  • Offline Offline
  • Posts: 4
Re: "Who is online" plugin (onlinestats)
« Reply #172 on: February 15, 2007, 08:18:15 am »

Look through codebase.php and comment out/delete anything you don't want.
thanx, I did it ... :) work perfect
Logged

natrlhy

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 77
Re: "Who is online" plugin (onlinestats)
« Reply #173 on: February 26, 2007, 05:00:38 am »

In the 1.7 version of this wonderful plugin I found some misspellings (Registred) and I have modified them in the lang/english.php file.
I also changed the date format for my taste to look like this:  Most users ever online: 4 on Sun, Feb 25 2007 at 7:10 pm

Code: [Select]
//language variables
$lang_plugin_onlinestats = array(
'name'                =>'Online Today',
'submit_button'        =>'Submit',
'cancel_button' =>'Cancel',
'reg_member'        =>' Registered member',
'reg_members'        =>' Registered members',
'have'                =>'We have ',
'most_recent'        =>'The newest registered user is: ',
'is'                =>'In total there is ',
'are'                =>'In total there are ',
'user'                =>' user online',
'users'                =>' users online',
'and'                =>' and ',
'guest'                =>' Guest',
'guests'        =>' Guests',
'record'        =>'Most users ever online: ',
'on'                =>' on ',
'since'                =>' online during the last ',
);
//for config
$lang_plugin_onlinestats_config = array(
 'config_text'        =>'How long do you want to keep users listed as online for before they are assumed to have gone ?
',
 'minute'        =>' Minutes',
 'remove'        =>'Remove the table that was used to store online data ?',
 'yes'                =>'Yes',
 'no'                =>'No',
);
// changed date format
$lang_plugin_onlinestats_date_fmt='%A, %B %d %Y at %l:%M %P';

I also wanted the "Online Today" table to be bold and I made the following modification to the codebase.php file. This took me a while! ;)

look for this code:

Code: [Select]
       starttable("100%", $lang_plugin_onlinestats['name']);
And change it to this:

Code: [Select]
       starttable("100%", "<b>".$lang_plugin_onlinestats['name']."</b>");
I also love having the usernames based on the group to have different colors and the following post still worked great for the 1.7 release:

http://forum.coppermine-gallery.net/index.php?topic=26532.msg154487#msg154487

I hope this is helpful for others  :)
Logged

natrlhy

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 77
Re: "Who is online" plugin (onlinestats)
« Reply #174 on: February 26, 2007, 08:21:25 pm »

I'm trying to figure out how to add some color to the section where this plugin displays the "Most users ever online:" section.

Here is the line I need to modify in the codebase.php file:

Code: [Select]
        echo $lang_plugin_onlinestats['record']."<b>". $CONFIG['record_online_users']."</b>" .$lang_plugin_onlinestats['on']."<b>".
localised_date($CONFIG['record_online_date'], $lang_plugin_onlinestats_date_fmt ) ."</b><br />"."</td></tr>";

I've tried several things but I just keep getting parsing errors.

Thanks!
Logged

François Keller

  • Dev Team member
  • Coppermine addict
  • ****
  • Country: fr
  • Offline Offline
  • Gender: Male
  • Posts: 9094
  • aka Frantz
    • Ma galerie
Re: "Who is online" plugin (onlinestats)
« Reply #175 on: February 26, 2007, 10:43:26 pm »

and what would you do exactly ?
Logged
Avez vous lu la DOC ? la FAQ ? et cherché sur le forum avant de poster ?
Did you read the DOC ? the FAQ ? and search the board before posting ?
Mon Blog

natrlhy

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 77
Re: "Who is online" plugin (onlinestats)
« Reply #176 on: February 26, 2007, 10:53:58 pm »

I've tried entering in code like:

        echo $lang_plugin_onlinestats['record']."<b>". $CONFIG['record_online_users']."</b>" .$lang_plugin_onlinestats['on']."<b>"."<span style="color:red;font-weight:bold;">".localised_date($CONFIG['record_online_date'], $lang_plugin_onlinestats_date_fmt ) ."</b><br /></span>"."</td></tr>";

With no luck... I'm not very savvy with PHP code, so with that said, I'm struggling with what goes where or if this can be done. Tis the price of a little pizazz :)
Logged

Nibbler

  • Guest
Re: "Who is online" plugin (onlinestats)
« Reply #177 on: February 26, 2007, 10:59:35 pm »

Use single quotes around this bit instead of double quotes

Code: [Select]
"<span style="color:red;font-weight:bold;">"

Code: [Select]
'<span style="color:red;font-weight:bold;">'
Logged

natrlhy

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 77
Re: "Who is online" plugin (onlinestats)
« Reply #178 on: February 26, 2007, 11:09:48 pm »

I tried so many different quote types and probably had them in the wrong spot.

Thanks!  This is working:

Code: [Select]
        echo $lang_plugin_onlinestats['record']."<b>".'<span style="color:#5EE548;font-weight:bold;">'.$CONFIG['record_online_users
']."</b></span>" .$lang_plugin_onlinestats['on']."<b>".'<span style="color:#5EE548;font-weight:bold;">'.localised_date($CONFIG['reco
rd_online_date'], $lang_plugin_onlinestats_date_fmt ) ."</b><br /></span>"."</td></tr>";

Syntax and placement is so key ;)  I just need to understand where all the . and " or ' go :)
« Last Edit: February 26, 2007, 11:34:05 pm by natrlhy »
Logged

lonely24

  • Coppermine newbie
  • Offline Offline
  • Posts: 12
Re: "Who is online" plugin (onlinestats)
« Reply #179 on: March 15, 2007, 11:26:55 am »

When i enable the plugin ,

I got message like this ,

Critical Error
There was an error while processing a database query 

MY CPG verision is the 1.4 latest version and integration with phpbb.

Is it coz of phpbb ?
Logged
Pages: 1 ... 5 6 7 8 [9] 10 11 12 13 ... 17   Go Up
 

Page created in 0.024 seconds with 20 queries.