March 11, 2010, 02:23:57 pm *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: cpg1.4.26 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.4.25 or older update to this latest version as soon as possible.
[more]
   Home   Help Search Board rules Login Register  
Pages: [1]   Go Down
  Print  
Author Topic: Summary of Hit Statistics  (Read 9910 times)
0 Members and 1 Guest are viewing this topic.
Paver Topic starter
Dev Team member
****
Gender: Male
United States United States

Posts: 1606


Paul Van Rompay


« on: November 01, 2006, 05:20:29 am »

This plugin is originally based on the discussion in this thread.  It provides a summary of the hit statistics kept by Coppermine (if you have set "Keep detailed hit statistics" on the config panel).  Coppermine gives you the details for each file/photo with a popup window linked on each file/photo (in the info box).  This plugin gives you a summary of the hit statistics overall.  I imagine that this plugin will add features as people contribute them, so feel free to submit code contributions on this thread for inclusion into future versions of this plugin.

Version 0.1 beta - initial release of the plugin by wrapping the code in the original support thread into the plugin system.  This version has not been tested thoroughly so please report any issues here.  This version gives you a summary of the hit statistics from the last N number of days sorted by IP address with number of hits.  The hits from each IP address can then be broken down and displayed in a table.

* cpg1.4_plugin_stats_hits_v0.1beta.zip (6.06 KB - downloaded 761 times.)
Logged
freynolds
Coppermine novice
*
Posts: 30


« Reply #1 on: November 01, 2006, 11:19:14 pm »

I've just tried out the plugin and it works great!

Paver thanks alot for this!

I will test it out and talk to you if there is anything not workin as it should.

Thanks again
Logged
christian
Coppermine newbie

Gender: Male
Posts: 16


WWW
« Reply #2 on: March 07, 2007, 10:02:33 pm »

Great plugin! And if you could do an automatic lookup in the members list ...  Roll Eyes
Christian
Logged
RArch
Coppermine newbie

Posts: 6


« Reply #3 on: August 12, 2008, 05:31:51 pm »

This plugin is working good on my server too.

Would it be possible to add some functionality so that it can convert server times to local times?
Logged
freynolds
Coppermine novice
*
Posts: 30


« Reply #4 on: August 12, 2008, 07:22:56 pm »

Rarch, I was impressed to hear a comment on the subject over two years ago, at the momment I'm not using a cooppermine gallery, facebook sort of replaced the need for it.
So I can't help you, but if you check the code you might be able to change the way is printed. just add the amount of hours you want it to change to the number before you print it and you might get what you want.

In line 52 of ip_watch.php

Code:
    echo "\n\n<TR><TD align=\"middle\">".date("D d-m h:i:s a",$row[sdate])."</TD>";

change
Code:
$row[sdate]

to

Code:
($row[sdate] + Timeshift)

And replace timeshift with the hours you want to correct for your server...

Tell me if it works for you.

Francisco.
Logged
freynolds
Coppermine novice
*
Posts: 30


« Reply #5 on: August 12, 2008, 07:23:55 pm »

Seconds not hours...
3660 is an hour.
Logged
maxymalny
Coppermine newbie

Gender: Male
Posts: 6


WWW
« Reply #6 on: August 13, 2008, 10:51:28 am »

Seconds not hours...
3660 is an hour.
3660??? Maybe 3600?
Logged
RArch
Coppermine newbie

Posts: 6


« Reply #7 on: August 13, 2008, 01:07:49 pm »

Yeah, its an old mod but its a great one for viewing those stats  Wink

Thanks for the info guys, it has helped.
Logged
RArch
Coppermine newbie

Posts: 6


« Reply #8 on: August 13, 2008, 02:38:33 pm »

I've modified the files from the original plugin to add a time zone option, where you can add/subtract hours from the server time to correct the displayed time should your web server be in a different time zone.

The files ip_watch.php and stats.php have changed, you just need to install the plugin (posted above) as normal and overwrite those two files with the ones in the attached zip.

Near the top of each file (line 13) there is the following new variable:

Code:
$timeshift = 3600 * 8; /** Adjust server time by adding 8 hours **/

You need to set this to the number of seconds (ie. 3600 * hours) that you want to add to the server time or a negative value if you need to remove time.

I've also added a link to lookup the ip address (line 26, using dnsstuff.com), you may edit this to add your favourite lookup site. I like an idea of my visitor come from.

PS. Within the Config options of Coppermine under "General Settings" you set the "Timezone difference relative to GMT" I wonder if there is way of using this to set the timeshift variable. Maybe someone would like that challenge and modify this again.

Thanks freynolds and Paver for sharing this plugin.

* Modified_stats_hits_files.zip (3.05 KB - downloaded 276 times.)
Logged
paquets
Coppermine novice
*
Posts: 37


« Reply #9 on: July 03, 2009, 07:26:28 pm »

Great plugin Paver. Would it be possible to also have the username with the IP address?
Logged
drownedgod
Coppermine newbie

Gender: Male
Philippines Philippines

Posts: 15


WWW
« Reply #10 on: July 13, 2009, 08:34:18 am »

I installed it but I got this. Help?

Code:
Fatal error: online_configure() [function.require]: Failed opening required './plugins/onlinestats/include/init.inc.php' (include_path='.:/usr/local/lib/php:/usr/local/lib/php/PEAR:/usr/local/share/pear') in /plugins/onlinestats/codebase.php on line 46
Logged
Joachim Müller
Administrator
*****
Gender: Male
Germany Germany

Posts: 46148


aka "GauGau"


WWW
« Reply #11 on: July 13, 2009, 10:17:52 am »

Means you haven't uploaded all files that belong to the plugin. Uninstall the plugin, delete the folder that contains the plugin files, get a fresh copy of the plugin archive, unzip preserbing the folder structure, upload the entire plugin's folder with all sub-folders that resided in the zip archive, install the plugin using the plugin manager. If that doesn't help, stay out of this announcement thread, but start an individual support request.
Logged
drownedgod
Coppermine newbie

Gender: Male
Philippines Philippines

Posts: 15


WWW
« Reply #12 on: July 13, 2009, 12:03:19 pm »

It worked. Thanks!
Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by SMF 1.1.11 | SMF © 2006-2009, Simple Machines LLC
Page created in 0.061 seconds with 18 queries.