Initial commit of website to git. Has the "old" ob3 website as the main site, and...
[dana/openbox-web.git] / oldwiki / extensions / firestats-mediawiki.php
1 <?php
2
3 // Edit this line to match your FireStats directory.
4 define('FS_PATH','/webspace/projects/openbox/firestats');
5
6 // This is the site ID of your MediaWiki site inside FireStats sites table.
7 // You need to add a MediaWiki site in the Sites tab in FireStats and then change the
8 // value here to match the ID.
9 // this will allow FireStats to show the statistics of your MediaWiki site seperated from your other sites.
10 //
11 // Note: This is optional, the default value will also work.
12 define('FS_SITE_ID',0);
13
14
15
16 require_once(FS_PATH.'/php/db-hit.php');
17 $wgHooks['LogPageLogHeader'][] = 'fs_mediawiki_hit';
18
19 function fs_mediawiki_hit($wiki_object)
20 {
21         if (isset($_REQUEST['gen']) || isset($_REQUEST['ctype'])) 
22         {
23                 return;
24         }
25         fs_add_site_hit(FS_SITE_ID);
26 }
27
28 ?>