source: extensions/url_uploader/main.inc.php @ 19804

Last change on this file since 19804 was 19804, checked in by mistic100, 11 years ago

add plugin URL Uploader

File size: 1.4 KB
Line 
1<?php 
2/*
3Plugin Name: URL Uploader
4Version: auto
5Description: Add photos from remote URL (see Admin->Photos->Add)
6Plugin URI: auto
7Author: Mistic
8Author URI: http://www.strangeplanet.fr
9*/
10
11defined('PHPWG_ROOT_PATH') or die('Hacking attempt!');
12
13
14// +-----------------------------------------------------------------------+
15// | Define plugin constants                                               |
16// +-----------------------------------------------------------------------+
17defined('URLUPLOADER_ID') or define('URLUPLOADER_ID', basename(dirname(__FILE__)));
18define('URLUPLOADER_PATH' ,   PHPWG_PLUGINS_PATH . URLUPLOADER_ID . '/');
19define('URLUPLOADER_ADMIN',   get_root_url() . 'admin.php?page=plugin-' . URLUPLOADER_ID);
20
21
22// +-----------------------------------------------------------------------+
23// | Add event handlers                                                    |
24// +-----------------------------------------------------------------------+
25if (defined('IN_ADMIN'))
26{
27  // admin plugins menu link
28  add_event_handler('get_admin_plugin_menu_links', 'urluploader_admin_plugin_menu_links');
29 
30  // new tab on photo page
31  add_event_handler('tabsheet_before_select', 'urluploader_tabsheet_before_select', EVENT_HANDLER_PRIORITY_NEUTRAL, 2);
32}
33
34// add API function
35add_event_handler('ws_add_methods', 'urluploader_ws_add_methods');
36
37include_once(URLUPLOADER_PATH . 'include/functions.inc.php');
38include_once(URLUPLOADER_PATH . 'include/ws_functions.inc.php');
39
40?>
Note: See TracBrowser for help on using the repository browser.