This module forks original one from https://github.com/ajaxray adding suport for Kohana's 3.2 log file format, which includes stack trace
MODPATH
bootstrap
filebootstrap.css
, style.css
, jquery.js
files in config file (copy it from MODPATH/logviewer/config/logviewer.php
to APPPATH/config/logviewer.php
and edit. You may skip this step, default assets will be used.MODPATH\logviewer/i18n/ru.php
for example. You may skip this step, if only English language is enough.It's completely self explanatory. Here are some points for quick refs -
LogViewer use standart Kohana naming convention, so you can easily extend it in your application. For example, if you use standart Auth module, and wish to limit access to LogViewer only for admins, create APPPATH/classes/Controller/Logs.php
file and type something like:
<?php defined('SYSPATH') or die('No direct script access.');
class Controller_Logs extends Kohana_Controller_Logs {
function before(){
$auth=new Auth_ORM(Kohana::$config->load('auth'));
if(!$auth->logged_in('admin'))
throw HTTP_Exception::factory(403,__('Access denied'))->request($this->request);
// skip next line, if you don't want to limit log erasure
$this->_allow_delete=$auth->logged_in('power_admin');
parent::before();
}
}
If you use your own authentication system, you may easily adapt this code to you conditions
modules/logviewer/init.php
modules/logviewer/views/logs/layout.php
accordingly.