English
GrafX Hit Counter (MySQL Edition)
Script by Matt Biscay
French



INTRO

GrafX Hit Counter is a hit counter displaying the results from a MySQL database. Simply add the 3 lines of code at the beginning of each page you want to track and the script will store the results so that you know which pages are the most accessed.



IMPORTANT

You cannot remove the copyright on all the pages of this script and you cannot say you made it yourself. This scipt is free for your own personal use. If you plan to use this script commercially then contact me. Consider also linking back to me if you find this script helpful and/or useful.



INSTALL
  1. Edit counter.php with your MySQL server details.
  2. To track a page, add this code on the very top of it:

    <?php
    $page = $_SERVER['PHP_SELF'];
    include('counter.php');
    ShowCount($page);
    ?>

  3. Run test.php to store some info in the base.
  4. Run view.php to extract the information.
  5. That's it!

HOW IT WORKS

The script stores the name of the page requested and how many times it was called in a MySQL table. View.php shows the table content.



REMINDER

  1. Don't forget to edit counter.php with your own info.


Copyright 2001-2017 Matt Biscay

 

 


English
GrafX Hit Counter (MySQL Edition)
Script par Matt Biscay
French



INTRO

GrafX Hit Counter est un compteur de hits qui se sert d'une base MySQL pour enregistrer et afficher les résultats. Il suffit d'ajouter les 3 lignes de code au début de chaque page comptabilisée: le script affichera les pages les plus demandées et affichera le graphique.



IMPORTANT

Ce script est gratuit pour votre site personnel. Vous ne pouvez pas enlever l'entête du copyright ni dire que vous l'avez écrit vous-même. Si vous souhaitez utiliser ce script commercialement, contactez moi.



INSTALLATION
  1. Editer counter.php avec les informations relatives à votre base MySQL.
  2. Pour comptabiliser une page, insérez ce code au tout début de votre page (avant la balise <html>):

    <?php
    $page = $_SERVER['PHP_SELF'];
    include('counter.php');
    ShowCount($page);
    ?>

  3. Lancez test.php pour enregistrer une valeur dans la base.
  4. Lancez view.php pour voir vos résultats.
  5. Fini!

FONCTIONNEMENT

Le script stocke les données dans une table MySQL. Le fichier view.php affiche le contenu de la table MySQL.



RAPPEL

  1. N'oubliez pas de changer les infos dans counter.php.


Copyright 2001-2017 Matt Biscay