1 | <?php |
---|
2 | // +-----------------------------------------------------------------------+ |
---|
3 | // | Manage Properties Photos plugin for Piwigo | |
---|
4 | // +-----------------------------------------------------------------------+ |
---|
5 | // | Copyright(C) 2014-2016 ddtddt http://temmii.com | |
---|
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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, | |
---|
19 | // | USA. | |
---|
20 | // +-----------------------------------------------------------------------+ |
---|
21 | /* |
---|
22 | Plugin Name: Manage Properties Photos |
---|
23 | Version: auto |
---|
24 | Description: Add properties on photo page and organize this |
---|
25 | Plugin URI: http://piwigo.org/ext/extension_view.php?eid=783 |
---|
26 | Author: ddtddt |
---|
27 | Author URI: http://temmii.com/ |
---|
28 | */ |
---|
29 | |
---|
30 | if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!'); |
---|
31 | |
---|
32 | global $prefixTable; |
---|
33 | |
---|
34 | define('ADD_PROP_PHOTO_DIR' , basename(dirname(__FILE__))); |
---|
35 | define('ADD_PROP_PHOTO_PATH' , PHPWG_PLUGINS_PATH . ADD_PROP_PHOTO_DIR . '/'); |
---|
36 | if (!defined('ADD_PROP_PHOTO_TABLE')) define('ADD_PROP_PHOTO_TABLE', $prefixeTable.'add_properties_photos'); |
---|
37 | if (!defined('ADD_PROP_PHOTO_DATA_TABLE')) define('ADD_PROP_PHOTO_DATA_TABLE', $prefixeTable.'add_properties_photos_data'); |
---|
38 | define('ADD_PROP_PHOTO_ADMIN',get_root_url().'admin.php?page=plugin-'.ADD_PROP_PHOTO_DIR); |
---|
39 | |
---|
40 | include_once(ADD_PROP_PHOTO_PATH . 'include/function.aip.inc.php'); |
---|
41 | |
---|
42 | // Plugin on picture page |
---|
43 | if (script_basename() == 'picture') |
---|
44 | { |
---|
45 | include_once(dirname(__FILE__).'/initpicture.php'); |
---|
46 | } |
---|
47 | |
---|
48 | |
---|
49 | // Plugin for admin |
---|
50 | if (script_basename() == 'admin') |
---|
51 | { |
---|
52 | include_once(dirname(__FILE__).'/initadmin.php'); |
---|
53 | } |
---|
54 | |
---|
55 | ?> |
---|