[example] mis à jour avec hook redirect + hook helpdesk

git-svn-id: https://forge.glpi-project.org/svn/example/trunk@12 349b9182-4a13-0410-896f-e5e9767dd1b3
This commit is contained in:
tsmr 2007-02-04 22:50:06 +00:00
parent 4e525ce3b2
commit b2b3269ff7
2 changed files with 8 additions and 1 deletions

View File

@ -39,7 +39,11 @@
define('GLPI_ROOT', '../..');
include (GLPI_ROOT . "/inc/includes.php");
if ($_SESSION["glpiactiveprofile"]["interface"] == "central")
commonHeader("TITRE", $_SERVER['PHP_SELF'],"plugins");
else
helpHeader("TITRE", $_SERVER['PHP_SELF']);
echo "This is the plugin index file";

View File

@ -41,6 +41,7 @@ function plugin_init_example() {
// Display a menu entry ?
$PLUGIN_HOOKS['menu_entry']['example'] = true;
$PLUGIN_HOOKS["helpdesk_menu_entry"]['example'] = true;
// Setup/Update functions
$PLUGIN_HOOKS['setup']['example'] = "plugin_setup_example";
// Config function
@ -60,6 +61,8 @@ function plugin_init_example() {
$PLUGIN_HOOKS['central_action']['example'] = 'plugin_central_action_example';
// Cron action
$PLUGIN_HOOKS['cron']['example'] = DAY_TIMESTAMP;
//redirect
$PLUGIN_HOOKS['redirect_page']['example']="example.form.php";
}