Insertion code in the pages
For the visits are counted you in every page your site put a code.
If the pages on your site are in PHP
Note:
The code with the path (path) calculated is available in the "Admin" once AllMyStats installed.
PHP Code to insert:
<?php
$Racine_abs = str_replace($_SERVER['PHP_SELF'],"",$_SERVER['SCRIPT_FILENAME']);
$nom_page='nom de la page';
require $Racine_abs.'/path/allmystats/visiteur.php';
?>
$nom_page is the name of the page, you can put the name you want for each page.
Example:
$nom_page = 'home page';
path is the path to access the directory allmystats
Example:
If the directory allmystats is the root of the site:
require $Racine_abs. 'allmystats/visiteur.php';
If the directory allmystats is in the directory stats site:
require $Racine_abs. 'stats/allmystats/visiteur.php';
To be sure that pages have been recorded views fully, it is preferable to put the code at the bottom of page
If the pages on your site are in html or htm
1st solution (best):
If you provide your host allows, add these two lines to the file .htaccess if it already exists if not create it.
AddType application / x-httpd-php. Html
AddType application / x-httpd-php. Htm
The HTML pages and htm will be treated as if they were PHP.
Then put the PHP code in each page of your site with tags <?php at the beginning and ?> at the end.
----------------------------------------------------------------
2nd solution:
Note: referring and keywords will not be counted.
Code simple:
<img src="path/allmystats/visiteur.php?nom_page=nom_de_la_page" width=0 height=0>
Note: path is the path on to access the directory allmystats
|