source: extensions/user_tags/init.php @ 7690

Last change on this file since 7690 was 6813, checked in by nikrou, 14 years ago

Update tags with an ajax request

File size: 2.2 KB
Line 
1<?php
2// +-----------------------------------------------------------------------+
3// | User Tags  - a plugin for Piwigo                                      |
4// +-----------------------------------------------------------------------+
5// | Copyright(C) 2010 Nicolas Roudaire             http://www.nikrou.net  |
6// +-----------------------------------------------------------------------+
7// | This program is free software; you can redistribute it and/or modify  |
8// | it under the terms of the GNU General Public License as published by  |
9// | the Free Software Foundation                                          |
10// |                                                                       |
11// | This program is distributed in the hope that it will be useful, but   |
12// | WITHOUT ANY WARRANTY; without even the implied warranty of            |
13// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU      |
14// | General Public License for more details.                              |
15// |                                                                       |
16// | You should have received a copy of the GNU General Public License     |
17// | along with this program; if not, write to the Free Software           |
18// | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,            |
19// | MA 02110-1301 USA.                                                    |
20// +-----------------------------------------------------------------------+
21
22if (!defined('PHPWG_ROOT_PATH')) {
23  die('Hacking attempt!');
24}
25
26define('T4U_PLUGIN_ROOT', dirname(__FILE__));
27
28include_once T4U_PLUGIN_ROOT . "/include/constants.inc.php";
29include_once T4U_PLUGIN_ROOT . "/include/t4u_config.class.php";
30
31load_language('plugin.lang', T4U_PLUGIN_LANG);
32
33$plugin_config = new t4u_Config(T4U_PLUGIN_ROOT, T4U_PLUGIN_NAME);
34$plugin_config->load_config();
35
36if (defined('IN_ADMIN')) { 
37  add_event_handler('get_admin_plugin_menu_links', 
38                    array($plugin_config, 'plugin_admin_menu')
39                    ); 
40  add_event_handler('get_popup_help_content', 
41                    array($plugin_config, 'get_admin_help'),
42                    EVENT_HANDLER_PRIORITY_NEUTRAL,
43                    2
44                    );
45} else {
46  include_once T4U_PLUGIN_ROOT . '/public.php';
47}
48
49set_plugin_data($plugin['id'], $plugin_config);
50?>
Note: See TracBrowser for help on using the repository browser.