Revision 2613,
1023 bytes
checked in by JcDenis, 13 years ago
(diff) |
Private mode : version 1.5 - Cleaner release
|
Line | |
---|
1 | <?php |
---|
2 | # -- BEGIN LICENSE BLOCK ---------------------------------- |
---|
3 | # |
---|
4 | # This file is part of Private mode, a plugin for Dotclear 2. |
---|
5 | # |
---|
6 | # Copyright (c) 2008-2010 Osku and contributors |
---|
7 | # |
---|
8 | # Licensed under the GPL version 2.0 license. |
---|
9 | # A copy of this license is available in LICENSE file or at |
---|
10 | # http://www.gnu.org/licenses/old-licenses/gpl-2.0.html |
---|
11 | # |
---|
12 | # -- END LICENSE BLOCK ------------------------------------ |
---|
13 | |
---|
14 | if (!defined('DC_CONTEXT_ADMIN')) { return; } |
---|
15 | |
---|
16 | $menu_class = ''; |
---|
17 | |
---|
18 | if ($core->blog->settings->private->private_flag) |
---|
19 | { |
---|
20 | $menu_class = 'private-blog'; |
---|
21 | } |
---|
22 | |
---|
23 | $core->addBehavior('adminPageHTMLHead','privateadminPageHTMLHead'); |
---|
24 | |
---|
25 | $_menu['Plugins']->addItem(__('Private mode'), |
---|
26 | 'plugin.php?p=private','index.php?pf=private/icon.png', |
---|
27 | preg_match('/plugin.php\?p=private(&.*)?$/',$_SERVER['REQUEST_URI']), |
---|
28 | $core->auth->check('admin',$core->blog->id), |
---|
29 | $menu_class |
---|
30 | ); |
---|
31 | |
---|
32 | function privateadminPageHTMLHead() |
---|
33 | { |
---|
34 | echo '<link rel="stylesheet" href="index.php?pf=private/style/admin.css"type="text/css" media="screen" />'."\n"; |
---|
35 | } |
---|
36 | ?> |
---|
Note: See
TracBrowser
for help on using the repository browser.