source: extensions/AMenuManager/main.inc.php @ 7851

Last change on this file since 7851 was 5545, checked in by grum, 15 years ago

Update the plugin for compatibility with Piwigo 2.1

  • Property svn:executable set to *
File size: 5.6 KB
RevLine 
[3681]1<?php
2/*
3Plugin Name: Advanced Menu Manager
[5421]4Version: 2.2.0
[3681]5Description: Gestion avancée du menu / Advanced management of menu
6Plugin URI: http://piwigo.org
7Author: Piwigo team
8Author URI: http://piwigo.org
9*/
10
11/*
12--------------------------------------------------------------------------------
13  Author     : Grum
14    email    : grum@grum.fr
[4382]15    website  : http://photos.grum.fr
[3681]16    PWG user : http://forum.piwigo.org/profile.php?id=3706
17
18    << May the Little SpaceFrog be with you ! >>
19--------------------------------------------------------------------------------
20
21:: HISTORY
22
23| release | date       |
24| 2.0.0b  | 2008/07/27 | * initial release with own blocks classes
25| 2.0.0   | 2008/10/23 | * first release for piwigo's blocks classes
[3683]26| 2.1.0   | 2009/07/26 | * add a functionality : random image can be changed
[3682]27|         |            |   every x seconds (from 0.5 to 60)
[3683]28|         |            | * bug resolved : random image block is displayed only
29|         |            |   if user have accessibility to more than 0 images
[4389]30|         |            |   random images are choosen in the accessible images
31|         |            |   for a user (permission + level)
[3683]32|         |            |   (cf. post:107877 on french forum)
33|         |            |   (cf. topic:14374 on french forum)
[4389]34| 2.1.1   | 2009/07/27 | * random picture is preloaded before the first ajax
35|         |            |   call assuming the display of a thumbnail even if
36|         |            |   javascript is disabled on the browser
[3690]37|         |            |   (cf. post:116807 on french forum)
38|         |            | * give the possibility to choose between an automatic
39|         |            |   and a fixed height for the block menu
40|         |            |   (cf. post:116804 on french forum)
41|         |            | * compatibility with Sylvia theme
42|         |            |   (cf. post:116800 on french forum)
[4274]43| 2.1.2   | 2009/11/16 | * adding new translations
44|         |            |    - es_ES
45|         |            |    - hu_HU (thx to sámli)
[4389]46| 2.1.3   | 2009/11/24 | * mantis: feature 1285
[4382]47|         |            |   move the js for "random image" in the the footer
[4363]48|         |            |   (having the js inside the <dl> tag was not w3c
49|         |            |   compliant)
[4389]50|         |            | * mantis: feature 1132
51|         |            |   Allowing order management for items in Piwigo's core
52|         |            |   blocks
53|         |            | * mantis: feature 1133
[4382]54|         |            |   Allowing to group content from Piwigo's core blocks
[4389]55|         |            | * mantis: feature 1278
56|         |            |   Allowing to manage access to menu items with a right
57|         |            |   management system
[4390]58|         |            | * mantis: feature 1100
59|         |            |   Random picture : compatibility with theme 'montblanc'
[4395]60| 2.1.4   | 2009/11/29 | * mantis: feature 1299
61|         |            |   Allows to manage access for the 'Admin' users
62|         |            | * mantis: feature 1298
63|         |            |   Users 'Webmaster' aren't managed
64|         |            | * mantis: feature 1297
65|         |            |   AMM don't works properly if a block 'menu' or
66|         |            |   'specials' is hidden
[4499]67| 2.1.5   | 2009/12/15 | * mantis: feature 1331
68|         |            |   JS code used to manage the random picture is always
69|         |            |   loaded even if there is no menubar
70|         |            | * adding new translations
71|         |            |    - zh_CN (thx mzs777)
72|         |            | * update translations
73|         |            |    - hu_HU (thx to sámli)
[4515]74| 2.1.6   | 2009/12/19 | * mantis: feature 1336
75|         |            |   Error message about an undefined var 'tabsheet' on
76|         |            |   the admin panel
[5421]77| 2.2.0   | 2010/03/28 | * updated for Piwigo 2.1 compatibility
78|         |            | * mantis: feature 1384
79|         |            |   Problem of length of title field in the custom menu
80|         |            |   module
81|         |            | * mantis: bug 1476
82|         |            |   Error message on login screen
83|         |            | * mantis: bug 1541
84|         |            |   Items order is not respected in admin pages
[3682]85|         |            |
[4382]86|         |            |
[4499]87|         |            |
88|         |            |
89|         |            |
90|         |            |
91|         |            |
[5421]92|         |            |
93|         |            |
94|         |            |
95|         |            |
[3681]96
97
98:: TO DO
99
100--------------------------------------------------------------------------------
101
102:: NFO
103  AMM_AIM : classe to manage plugin integration into plugin menu
104  AMM_AIP : classe to manage plugin admin pages
105  AMM_PIP : classe to manage plugin public integration
106
107--------------------------------------------------------------------------------
108*/
109
110// pour faciliter le debug - make debug easier :o)
111//ini_set('error_reporting', E_ALL);
112//ini_set('display_errors', true);
113
114if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
115
116define('AMM_DIR' , basename(dirname(__FILE__)));
117define('AMM_PATH' , PHPWG_PLUGINS_PATH . AMM_DIR . '/');
118
[5421]119include_once('amm_version.inc.php'); // => Don't forget to update this file !!
[3681]120
121global $prefixeTable, $page;
122
123
124if(defined('IN_ADMIN'))
125{
126  //AMM admin part loaded and active only if in admin page
127  include_once("amm_aim.class.inc.php");
128  $obj = new AMM_AIM($prefixeTable, __FILE__);
[5545]129  $obj->initEvents();
[3681]130  set_plugin_data($plugin['id'], $obj);
131}
132else
133{
134  //AMM public part loaded and active only if in public page
135  include_once("amm_pip.class.inc.php");
136  $obj = new AMM_PIP($prefixeTable, __FILE__);
137  set_plugin_data($plugin['id'], $obj);
138}
139
140
141?>
Note: See TracBrowser for help on using the repository browser.