root/devel/mod/admin/index.php

Revision 1539, 1.5 kB (checked in by renato, 10 months ago)

Setting prop svn:eol-style in LOTS of files.

  • Property svn:mime-type set to text/plain
  • Property svn:eol-style set to native
Line 
1 <?php
2
3     //    ELGG main admin panel page
4
5     // Run includes
6     require_once(dirname(dirname(__FILE__))."/../includes.php");
7
8     define("context", "admin");
9     require_login('admin');
10
11     templates_page_setup();
12
13     // controller ;-)
14     $do = optional_param('do');
15     switch ($do) {
16         case'spam':
17             $title = __gettext('Spam blocking');
18             $body = run('admin:spam');
19             break;
20         case 'flags':
21             $title = __gettext('Content flags');
22             $body = run('admin:contentflags');
23             break;
24         case 'users':
25             $title = __gettext('Manage users');
26             $view = optional_param('view');
27             switch ($view) {
28                 case 'add':
29                     $title .= ' :: ' . __gettext('Add multiple');
30                     $body = run('admin:users:add');
31                     break;
32                 case 'admin':
33                     $title .= ' :: ' . __gettext('Administrators');
34                     $body = run('admin:users:admin');
35                     break;
36                 case 'banned':
37                     $title .= ' :: ' . __gettext('Banned');
38                     $body = run('admin:users:banned');
39                     break;
40                 default:
41                     $body = run('admin:users');
42                     break;
43             }
44             break;
45         default:
46             $title = __gettext('Administration');
47             $body = run('admin:main');
48             break;
49     }
50
51     // view :-D
52     templates_page_output($title, $body);
53 ?>
Note: See TracBrowser for help on using the browser.