source: extensions/set_plugins/admin.php @ 11102

Last change on this file since 11102 was 11102, checked in by cljosse, 13 years ago

[extensions] set_plugins fix bugs on redirect_url

File size: 1.7 KB
Line 
1<?php
2// Chech whether we are indeed included by Piwigo.
3if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
4
5// Fetch the template.
6global $template;
7 $redirect_url = get_root_url().'admin.php?page='.'plugins_list';
8  redirect($redirect_url);       
9include_once(SET_PLUGINS_PATH."include/constants.php");           
10include_once(SET_PLUGINS_PATH.'include/affiche.php');
11
12
13include_once(PHPWG_ROOT_PATH.'admin/include/functions.php');
14include_once (PHPWG_ROOT_PATH.'admin/include/tabsheet.class.php');
15$my_base_url = get_admin_plugin_menu_link(__FILE__);
16
17$tabsheet = new tabsheet();
18$tabsheet->add( 'set_plugins_admin',
19                l10n('admin'),
20                $my_base_url.'&amp;tab=set_plugins_admin'
21                           );
22 /*     
23$tabsheet->add( 'set_plugins_help',
24                l10n('help'),
25                $my_base_url.'&amp;tab=set_plugins_help'
26                           );
27                           
28        */         
29                           
30        if (!isset($_GET['tab']))
31           $page['tab'] = 'set_plugins_admin';
32else
33       $page['tab'] = $_GET['tab'];     
34           
35                   
36$tabsheet->select($page['tab']);
37$tabsheet->assign();
38//======================================================================
39// Add our template to the global template
40$template->set_filenames(
41  array(
42    'plugin' => dirname(__FILE__).'/admin.tpl'
43  )         
44);
45
46//===============================================================================
47 if(isset($activate)){
48                    $template->assign( array( 
49                        'U_ACTION' => $activate
50                                                                                        )
51                                                                        );     
52
53                  }
54
55                    $page['tab'] = 'plugins_list';
56
57           //       "admin.php?page=plugins_list"
58
59
60// Assign the template contents to ADMIN_CONTENT
61$template->assign_var_from_handle('ADMIN_CONTENT', 'plugin');   
62
63
64?>
Note: See TracBrowser for help on using the repository browser.