[0] | 1 | <?php |
---|
| 2 | # -- BEGIN LICENSE BLOCK --------------------------------------- |
---|
| 3 | # |
---|
| 4 | # This file is part of Dotclear 2. |
---|
| 5 | # |
---|
[1179] | 6 | # Copyright (c) 2003-2013 Olivier Meunier & Association Dotclear |
---|
[0] | 7 | # Licensed under the GPL version 2.0 license. |
---|
| 8 | # See LICENSE file or |
---|
| 9 | # http://www.gnu.org/licenses/old-licenses/gpl-2.0.html |
---|
| 10 | # |
---|
| 11 | # -- END LICENSE BLOCK ----------------------------------------- |
---|
| 12 | if (!defined('DC_CONTEXT_ADMIN')) { return; } |
---|
| 13 | |
---|
| 14 | $core->addBehavior('adminDashboardIcons','blogroll_dashboard'); |
---|
[3] | 15 | $core->addBehavior('adminDashboardFavs','blogroll_dashboard_favs'); |
---|
[1502] | 16 | $core->addBehavior('adminUsersActionsHeaders','blogroll_users_actions_headers'); |
---|
| 17 | |
---|
[0] | 18 | function blogroll_dashboard($core,$icons) |
---|
| 19 | { |
---|
| 20 | $icons['blogroll'] = new ArrayObject(array(__('Blogroll'),'plugin.php?p=blogroll','index.php?pf=blogroll/icon.png')); |
---|
| 21 | } |
---|
[3] | 22 | function blogroll_dashboard_favs($core,$favs) |
---|
| 23 | { |
---|
[324] | 24 | $favs['blogroll'] = new ArrayObject(array('blogroll','Blogroll','plugin.php?p=blogroll', |
---|
[3] | 25 | 'index.php?pf=blogroll/icon-small.png','index.php?pf=blogroll/icon.png', |
---|
| 26 | 'usage,contentadmin',null,null)); |
---|
| 27 | } |
---|
[1502] | 28 | function blogroll_users_actions_headers() |
---|
| 29 | { |
---|
| 30 | return dcPage::jsLoad('index.php?pf=blogroll/_users_actions.js'); |
---|
| 31 | } |
---|
[0] | 32 | |
---|
[1296] | 33 | $_menu['Blog']->addItem(__('Blogroll'),'plugin.php?p=blogroll','index.php?pf=blogroll/icon-small.png', |
---|
[0] | 34 | preg_match('/plugin.php\?p=blogroll(&.*)?$/',$_SERVER['REQUEST_URI']), |
---|
| 35 | $core->auth->check('usage,contentadmin',$core->blog->id)); |
---|
| 36 | |
---|
| 37 | $core->auth->setPermissionType('blogroll',__('manage blogroll')); |
---|
| 38 | |
---|
| 39 | require dirname(__FILE__).'/_widgets.php'; |
---|
| 40 | ?> |
---|