Simple stats collection with CodeIgniter hooks |
Hi. After hours of googling I find an idea to track users journey throughout the site and to get some quantitative data on on the usage of the application. For example, I want to know when they get connected, the pages they visited (even the functions they called). This is how I proceed.
1) in application/config/config.php I replace this line : Code: $config['enable_hooks'] = FALSE; Code: $config['enable_hooks'] = TRUE; Code: $hook['post_controller_constructor'] = array( CREATE TABLE `audit` ( `auditId` int(11) NOT NULL AUTO_INCREMENT, `userId` varchar(100) NOT NULL, `adresseIp` varchar(100) NOT NULL, `referer` varchar(200) DEFAULT NULL, `controller` varchar(50) DEFAULT NULL, `fonction` varchar(100) DEFAULT NULL, `url` varchar(250) DEFAULT NULL, `navigator` varchar(100) NOT NULL, `dateAction` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, `domain` varchar(100) DEFAULT NULL, `pageCourant` varchar(200) DEFAULT NULL, PRIMARY KEY (`auditId`) ) 4) Here is my controller: PHP Code: <?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); But I get this error: Unable to locate the specified class: Session.php Why? Please help. Here is the tutorial i follow:http://7degrees.co.uk/blog/simple-stats-...ter-hooks/ |
Messages In This Thread |
Simple stats collection with CodeIgniter hooks - by Hyper-X - 07-13-2015, 01:57 AM
RE: Simple stats collection with CodeIgniter hooks - by gadelat - 07-13-2015, 02:10 AM
RE: Simple stats collection with CodeIgniter hooks - by Hyper-X - 07-13-2015, 02:35 AM
RE: Simple stats collection with CodeIgniter hooks - by kenjis - 07-13-2015, 03:55 AM
RE: Simple stats collection with CodeIgniter hooks - by Hyper-X - 07-13-2015, 04:13 AM
|