source: extensions/ContestResults/admin/admin.php @ 9419

Last change on this file since 9419 was 9419, checked in by mistic100, 13 years ago

[extensions] ContestResults

  • add messages on admin pages
File size: 1.5 KB
Line 
1<?php
2if(!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
3
4load_language('plugin.lang', CR_PATH);
5$conf['ContestResults'] = unserialize($conf['ContestResults']);
6
7// +-----------------------------------------------------------------------+
8//                              Tabsheet
9// +-----------------------------------------------------------------------+
10include_once(PHPWG_ROOT_PATH.'admin/include/tabsheet.class.php');
11$page['tab'] = (isset($_GET['tab'])) ? $_GET['tab'] : $page['tab'] = 'manage';
12       
13$tabsheet = new tabsheet();
14$tabsheet->add('manage', l10n('CR_manage_tab'), CR_ADMIN . '&amp;tab=manage');  // Gestion des concours
15$tabsheet->add('new', l10n('CR_new_tab'), CR_ADMIN . '&amp;tab=new');                   // Ajouter un nouveau concours
16if (isset($_GET['contest_id'])) {                                                                                               // Editer le concours | Résultats du concours
17        $tabsheet->add($page['tab'], l10n('CR_'.$page['tab'].'_tab'), CR_ADMIN . '&amp;tab=' . $page['tab'] . '&amp;contest_id=' . $_GET['contest_id']);
18}
19$tabsheet->add('config', l10n('Configuration'), CR_ADMIN . '&amp;tab=config');  // Configuration
20$tabsheet->select($page['tab']);
21$tabsheet->assign();
22
23// +-----------------------------------------------------------------------+
24//                              Template
25// +-----------------------------------------------------------------------+
26$template->assign('CR_VERSION', CR_NAME . ' ' . CR_VERSION);
27$template->assign('CR_PATH', CR_PATH);
28if ($page['tab'] == 'edit') { $page['tab'] = 'new'; } // L'édition se fait sur la page de création
29include(CR_PATH.'admin/'.$page['tab'].'.php');
30?>
Note: See TracBrowser for help on using the repository browser.