1 | <?php |
---|
2 | /* |
---|
3 | Plugin Name: Contact Form |
---|
4 | Version: auto |
---|
5 | Description: Add a "Contact" item in the Menu block to offer a contact form to users |
---|
6 | Plugin URI: http://piwigo.org/ext/extension_view.php?eid=304 |
---|
7 | Author: Criss, Gotcha |
---|
8 | Author URI: http://piwigo.org/ |
---|
9 | */ |
---|
10 | |
---|
11 | if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!'); |
---|
12 | |
---|
13 | define('CF_PATH', PHPWG_PLUGINS_PATH.basename(dirname(__FILE__)).'/'); |
---|
14 | define('CF_ROOT', dirname(__FILE__).'/'); |
---|
15 | include_once(CF_PATH . 'include/cf_common.inc.php'); |
---|
16 | |
---|
17 | $cf_plugin = new CF_Plugin($plugin['id']); |
---|
18 | add_event_handler('loc_begin_index', |
---|
19 | array(&$cf_plugin, 'loc_begin_index')); |
---|
20 | add_event_handler('loc_begin_page_tail', |
---|
21 | array(&$cf_plugin, 'loc_begin_page_header')); |
---|
22 | add_event_handler('blockmanager_apply', |
---|
23 | array(&$cf_plugin, 'blockmanager_apply')); |
---|
24 | add_event_handler('loc_end_index', |
---|
25 | array(&$cf_plugin, 'loc_end_index')); |
---|
26 | add_event_handler('loc_end_page_tail', |
---|
27 | array(&$cf_plugin, 'loc_end_page_tail')); |
---|
28 | if(defined('IN_ADMIN')) { |
---|
29 | add_event_handler('get_admin_plugin_menu_links', |
---|
30 | array(&$cf_plugin, 'get_admin_plugin_menu_links')); |
---|
31 | } |
---|
32 | set_plugin_data($plugin['id'], $cf_plugin); |
---|
33 | ?> |
---|