|
From: <ir...@us...> - 2013-04-17 05:06:02
|
Revision: 11390
http://sourceforge.net/p/xoops/svn/11390
Author: irmtfan
Date: 2013-04-17 05:05:57 +0000 (Wed, 17 Apr 2013)
Log Message:
-----------
- change version to 1.01 Final (2013/04/17)
- fix and improve: add eventCoreIncludeFunctionsRedirectheader to log redirects because usually prorammers use exit() after redirect_header function. in include/log.php and preloads/core.php(2013/04/17)
Modified Paths:
--------------
XoopsModules/userlog/trunk/userlog/docs/changelog.txt
XoopsModules/userlog/trunk/userlog/docs/readme.txt
XoopsModules/userlog/trunk/userlog/include/log.php
XoopsModules/userlog/trunk/userlog/preloads/core.php
XoopsModules/userlog/trunk/userlog/xoops_version.php
Modified: XoopsModules/userlog/trunk/userlog/docs/changelog.txt
===================================================================
--- XoopsModules/userlog/trunk/userlog/docs/changelog.txt 2013-04-17 01:49:19 UTC (rev 11389)
+++ XoopsModules/userlog/trunk/userlog/docs/changelog.txt 2013-04-17 05:05:57 UTC (rev 11390)
@@ -2,6 +2,8 @@
Changelog:
VERSION 1.01:
+- change version to 1.01 Final (2013/04/17)
+- fix and improve: add eventCoreIncludeFunctionsRedirectheader to log redirects because usually prorammers use exit() after redirect_header function. in include/log.php and preloads/core.php(2013/04/17)
- fix: empty smarty variables cause some errors in templates. in admin/logs.php (2013/04/16)
- add: search logs by using a setting (logby-unique_id) in templates/userlog_admin_sets.html (2013/04/13)
- fix: sometimes xoops core getGroups() funxtion return duplicate groups in class/setting.php and admin/stats.php (2013/04/13)
Modified: XoopsModules/userlog/trunk/userlog/docs/readme.txt
===================================================================
--- XoopsModules/userlog/trunk/userlog/docs/readme.txt 2013-04-17 01:49:19 UTC (rev 11389)
+++ XoopsModules/userlog/trunk/userlog/docs/readme.txt 2013-04-17 05:05:57 UTC (rev 11390)
@@ -4,6 +4,36 @@
=========================
XOOPS 2.5.5 php 5.3 mysql 5.0
+Features:
+=========================
+- Log user activities and navigations.
+ Examples:
+ 1- The possibility to list all the IPs used from a certain user, and conversely to list all the users logged from a defined IP to find duplicate users.
+ 2- Find deleted items from your database.
+ 3- Find admin user activities(webmasters, moderators, ...)
+ 4- Find users who come to your site from Google.
+
+- Can log users by getting User ID, User group or visitor IP.
+- Logs can be stored in file, database or both.
+- Any below user information and/or page data can be selected to be logged.
+[quote]
+User ID,Username,Is Admin?(y/n),Groups,User Last Visit,User IP,User agent,URL (Request URI),Script name,Referer URI,Page title,Is Page admin?(y/n),Module dirname,Module name,Item name,Item ID,Request method (GET, POST, ...),$_GET,$_POST,$_REQUEST,$_FILES,$_ENV,$_SESSION,$_COOKIE,Headers list,Logger
+[/quote]
+- Any active module in your installation can be selected and userlog will log users activities only in those modules.
+- You can navigate/delete/purge/export to CSV user logs in admin/logs.
+- You can render logs from database or file source engine in admin/logs.php.
+- To search for logs based on a criteria you have an advance form in admin/logs.php
+- You can see/delete/rename/copy/merge/compress(zip)/export to CSV log files in admin/file.php.
+- You can see total module views, total user views, total group views in admin/stats.php
+- you have an advance form to see any item views using some criteria like what is the module/link/log time/viewer uid/viewer group id of the item in admin/stats.php
+- by activating the views block you can set a most viewed items in a module or in the whole website in a specific period of time. e.g.: today most viewed (hot) news
+- You can set the module as Active or Idle in preferences.
+- If you need to store logs in a file, you can set the working path, working file size, working file name, ... in preferences.
+- If you need to store logs in database, you can set the maximum logs thresholds (maximum number of logs and maximum time that logs are stored in the database) in preferences.
+- Can be used as a backup/restore tool.
+- Used JSON format to store arrays to database for better performance (instead of xoops core serialize).
+
+
To Install
=========================
1- upload the userlog to /modules/userlog (upload the compressed file and decompressed via Cpanel is the best way to insure all files are correctly uploaded)
Modified: XoopsModules/userlog/trunk/userlog/include/log.php
===================================================================
--- XoopsModules/userlog/trunk/userlog/include/log.php 2013-04-17 01:49:19 UTC (rev 11389)
+++ XoopsModules/userlog/trunk/userlog/include/log.php 2013-04-17 05:05:57 UTC (rev 11390)
@@ -80,4 +80,27 @@
$statsObj->updateAll("log", $Userlog->getConfig("probstats")); // default prob = 10
}
// update all time stats
-$statsObj->updateAll("log", $Userlog->getConfig("probstatsallhit")); // default prob = 1
\ No newline at end of file
+$statsObj->updateAll("log", $Userlog->getConfig("probstatsallhit")); // default prob = 1
+
+// START to log redirects when $xoopsConfig['redirect_message_ajax'] = true
+// We need to shift the position of userlog to the top of 'system_modules_active' cache file list.
+// because to log redirect pages when $xoopsConfig['redirect_message_ajax'] = true IF eventCoreIncludeFunctionsRedirectheader in system module runs first it will exit()
+// IMO It is a bug in XOOPS255/modules/system/preloads/core.php
+// IMO exit() should be commented or we should find some way to make sure all eventCoreIncludeFunctionsRedirectheader events will run before any exit();
+/*
+if (!headers_sent() && isset($xoopsConfig['redirect_message_ajax']) && $xoopsConfig['redirect_message_ajax']) {
+ $_SESSION['redirect_message'] = $args[2];
+ header("Location: " . preg_replace("/[&]amp;/i", '&', $url));
+ exit(); // IMO exit() should be commented
+}
+*/
+if ($modules_list = XoopsCache::read('system_modules_active')) {
+ $key = array_search(USERLOG_DIRNAME, $modules_list);
+ // if userlog is not in the top
+ if ($key != 0) {
+ unset($modules_list[$key]);
+ array_unshift($modules_list, USERLOG_DIRNAME);
+ XoopsCache::write('system_modules_active', $modules_list);
+ }
+}
+// END to log redirects when $xoopsConfig['redirect_message_ajax'] = true
\ No newline at end of file
Modified: XoopsModules/userlog/trunk/userlog/preloads/core.php
===================================================================
--- XoopsModules/userlog/trunk/userlog/preloads/core.php 2013-04-17 01:49:19 UTC (rev 11389)
+++ XoopsModules/userlog/trunk/userlog/preloads/core.php 2013-04-17 05:05:57 UTC (rev 11390)
@@ -29,6 +29,12 @@
include dirname(dirname(__FILE__)) . '/include/log.php';
}
+ // to log redirects because usually prorammers use exit() after redirect_header function.
+ function eventCoreIncludeFunctionsRedirectheader($args)
+ {
+ include dirname(dirname(__FILE__)) . '/include/log.php';
+ }
+
// in XOOPS255/index.php (homepage) when no module is set for start page there is a bug in XOOPS255/header.php exit() should be commented
/*$xoopsPreload->triggerEvent('core.header.checkcache');
if ($xoTheme->checkCache()) {
Modified: XoopsModules/userlog/trunk/userlog/xoops_version.php
===================================================================
--- XoopsModules/userlog/trunk/userlog/xoops_version.php 2013-04-17 01:49:19 UTC (rev 11389)
+++ XoopsModules/userlog/trunk/userlog/xoops_version.php 2013-04-17 05:05:57 UTC (rev 11390)
@@ -28,7 +28,7 @@
$modversion['version'] = '1.01';
$modversion['author'] = 'xoops.org (irmtfan)';
$modversion['nickname'] = 'irmtfan';
-$modversion['credits'] = 'The XOOPS Project Team, trabis, irmtfan, mamba, tatane, Cesag, zyspec';
+$modversion['credits'] = 'The XOOPS Project Team, trabis, irmtfan, mamba, tatane, Cesag, zyspec, blackrx';
$modversion['license'] = 'GNU GPL 2.0';
$modversion['license_url'] = 'www.gnu.org/licenses/gpl-2.0.html/';
$modversion['official'] = 0;
@@ -38,10 +38,10 @@
$modversion['onUninstall'] = 'include/module.php';
//about
-$modversion['release_date'] = '2013/04/07';
+$modversion['release_date'] = '2013/04/20';
$modversion['module_website_url'] = 'http://www.xoops.org/';
$modversion['module_website_name'] = 'XOOPS';
-$modversion['module_status'] = 'RC 1';
+$modversion['module_status'] = 'Final';
$modversion['min_php'] = '5.3';
$modversion['min_xoops'] = '2.5.5';
$modversion['min_db'] = array('mysql' => '5.0.7', 'mysqli' => '5.0.7');
|