Menu

Tree [r4] /
 History

HTTPS access


File Date Author Commit
 images 2009-06-09 lucianogrippa [r2] edit readme and install files
 images2 2009-06-09 lucianogrippa [r2] edit readme and install files
 images2_ani 2009-06-09 lucianogrippa [r2] edit readme and install files
 images3 2009-06-09 lucianogrippa [r2] edit readme and install files
 images3_ani 2009-06-09 lucianogrippa [r2] edit readme and install files
 images_ani 2009-06-09 lucianogrippa [r2] edit readme and install files
 nbproject 2009-08-03 lucianogrippa [r4]
 INSTALL 2009-06-09 lucianogrippa [r2] edit readme and install files
 README 2009-06-09 lucianogrippa [r2] edit readme and install files
 counter.php 2009-06-09 lucianogrippa [r2] edit readme and install files
 database.sql 2009-06-09 lucianogrippa [r2] edit readme and install files
 db.php 2009-08-03 lucianogrippa [r4]
 esempio.php 2009-08-03 lucianogrippa [r4]
 gnu-sm.jpg 2009-06-09 lucianogrippa [r1] invio files
 screenshot.gif 2009-06-09 lucianogrippa [r3] edit readme and install files

Read Me

[it]
Il contatore ha come caratteristica non solo il conteggio dei click ma anche
il fatto di bloccare il conteggio se la pagina viene aggiornata più volte dallo stesso utente
in un arco di tempo che può essere impostato sia in fase di configurazione che in fase di esecuzione.
Il conteggio e’ legato ad un id che identifica la risorsa da contare e quindi nella stessa pagina possiamo inserire piu contatori diversi
con ids diversi e fare in modo che vengano effettuati due conteggi diversi ,

Richiede:

Database MYSQL versione 4 o superiore
PHP 4,5

per utilizzarlo basta osservare il seguente codice


1- include('counter.php');->include la classe del contatore
2- $id_res = "homepage";->fissa un id della risorsa da contare
3- $clsCount = new EECounter($id_res);->inizializza il contatore
4- $clsCount->updateCounter();->mostra il contatore

di default il contatore riconosce l'indirizzo ip dell'utente , se è la prima volta
che accede alla pagina viene conteggiato se accede per la seconda volta in un arco
di tempo inferiore a 300 minuti non viene conteggiato.
Per modificare il tempo di aggiornamento basta cambiare  la proprietà
EECounter->ip_lock_timeout (timeout espresso in minuti)

Ad esempio: si vuole aggiornare il conteggio tra click successi ogni 10 minuti

1- include('counter.php');
2- $id_res = "homepage";
3- $clsCount = new EECounter($id_res);
4- clsCount->ip_lock_timeout = 10;
4- $clsCount->updateCounter();

Per cambiare il look al contatore basta cambiare il valore di due proprietà
EECounter->img indica la directori dove sono presenti le immagini dei digits
EECounter->animated_img directory in cui sono presenti le directory animate


[en]

The counter is a feature not only the count of clicks but also
the fact of stopping the counting when a page is updated several times by the same user
in a time that can be set when the configuration at run time.
The counting is related to an id which identifies the resource and then to count on the same page we can add more counters with several different ids and ensure that they are made two different counts.

Requires:

MySQL Database version 4 or higher
PHP 4.5

Just look to use the following code


1 - include ( 'counter.php');-> include the class of the meter
2 - $ id_res = "homepage" -> id of a fixed asset to count
3 - $ clsCount = new EECounter ($ id_res) -> initialize the counter
4 - $ clsCount-> updateCounter ();-> show the meter

default, the meter recognizes the ip address of the user, if this is the first time
that accesses to the page if access is counted for the second time in a bow
of less than 300 minutes is not counted.
To change the time to update just to change the property
EECounter-> ip_lock_timeout (timeout in minutes)

For example: you want to update the count of successes click every 10 minutes

1 - include ( 'counter.php');
2 - $ id_res = "homepage";
3 - $ clsCount = new EECounter ($ id_res);
4 - clsCount-> ip_lock_timeout = 10;
4 - $ clsCount-> updateCounter ();

To change the look enough to the meter to change the value of two properties
EECounter-> img indicates the directory where you can find images of digits
EECounter-> animated_img directory where the directories are animated