Advanced search  

News:

cpg1.5.48 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.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Number of online users in stats bar  (Read 2128 times)

0 Members and 1 Guest are viewing this topic.

jolly

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Number of online users in stats bar
« on: June 18, 2009, 07:09:37 pm »

I know, it was multi threads about showing users online, but no one was about number users in stats bar certainly.

I have a little code, which showing a currently number of online users:
Code: [Select]
<script type='text/javascript' src='http://liczniki.org/hit.php?l=nidhhog&o=1'></script>
Now, i want to display number generated by this script, just before numbers of total files.
For example:

22 users online, 832 files in 2 category and 8 albums - display 74832 times.

I guess it is easy, but i dont know php at all. Could somen help me ?

Thank you for cooperate.
Logged

jolly

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 34
Re: Number of online users in stats bar
« Reply #1 on: June 24, 2009, 02:17:20 pm »

No ideas?

IMO,  I should save that java code as a variable and edit the language file and add this variable in this line:
Code: [Select]
'stat1' => '<b>[pictures]</b> files in <b>[albums]</b> albums and <b>[cat]</b> categories with <b>[comments]</b> comments viewed <b>[views]</b> times',
Could anyone help ?
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Number of online users in stats bar
« Reply #2 on: June 24, 2009, 02:37:13 pm »

1) Java is not JavaScript
2) The code you posted is just wishfull thinking.
3) PHP is executed on the server first, JavaScript is exectued on the client afterwards. The method to accomplish things vice versa is what makes many Ajax-driven applications tick, and what makes coding them far from trivial

So: what you're up to is technically possible, but definitely not with the poor detail level you have posted so far. I strongly doubt that someone will be ready to code this for you for free.
Logged
Pages: [1]   Go Up
 

Page created in 0.027 seconds with 21 queries.