source: extensions/Prune_History/main.inc.php @ 18489

Last change on this file since 18489 was 18489, checked in by Eric, 12 years ago

Next version is 1.0.6:
Update uk_UA, thanks to : animan
Update it_IT, thanks to : Ericnet, virgigiole
Add ru_RU, thanks to : nadusha, rocket
Add sk_SK, thanks to : dodo
Add es_ES, thanks to : jpr928
Add da_DK, thanks to : Kaare

  • Property svn:eol-style set to LF
File size: 967 bytes
Line 
1<?php
2/*
3Plugin Name: Prune History
4Version: auto
5Description: Based on original History_cleanup plugin from VDigital, this plugin allows to manually or automatically prune history table according to configurable criteria
6Plugin URI: http://piwigo.org/ext/extension_view.php?eid=604
7Author: Eric
8Author URI: http://www.infernoweb.net
9*/
10
11/* See release history and changes in changelog.txt file */
12
13if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
14
15if(!defined('PH_PATH'))
16{
17  define('PH_PATH' , PHPWG_PLUGINS_PATH.basename(dirname(__FILE__)).'/');
18}
19
20global $conf;
21
22include_once (PH_PATH.'include/functions.inc.php');
23
24load_language('plugin.lang', PH_PATH);
25$conf_PH = unserialize($conf['PruneHistory']);
26
27
28/* Plugin administration */
29add_event_handler('get_admin_plugin_menu_links', 'PH_admin_menu');
30
31
32/* Prune automation on user login */
33if (isset($conf_PH[1]) and $conf_PH[1] == 'true')
34{
35  add_event_handler('login_success', 'history_autoprune' );
36}
37?>
Note: See TracBrowser for help on using the repository browser.