Plugins administration completed.
[squirrelmail.git] / plugins / administrator / setup.php
CommitLineData
abd7a3f8 1<?php
2
3/**
4 * setup.php
5 *
6 * Copyright (c) 1999-2002 The SquirrelMail Project Team
7 * Licensed under the GNU GPL. For full terms see the file COPYING.
8 *
9 * Administrator plugin. Allows remote administration. Philippe Mingo
10 *
11 * $Id$
12 */
13
14function squirrelmail_plugin_init_administrator() {
15 global $squirrelmail_plugin_hooks, $username;
16
17 if ( $adm_id = fileowner('../config/config.php') ) {
18 $adm = posix_getpwuid( $adm_id );
b11ea636 19 if ( $username == $adm['name'] ) {
abd7a3f8 20 $squirrelmail_plugin_hooks['optpage_register_block']['administrator'] =
91e811f0 21 'squirrelmail_administrator_optpage_register_block';
abd7a3f8 22 }
23 }
24}
25
91e811f0 26function squirrelmail_administrator_optpage_register_block() {
abd7a3f8 27 global $optpage_blocks;
28 global $AllowSpamFilters;
29
30 $optpage_blocks[] = array(
31 'name' => _("Administration"),
32 'url' => '../plugins/administrator/options.php',
6a9acbca 33 'desc' => _("This module allows administrators to manage SquirrelMail main configuration remotely."),
abd7a3f8 34 'js' => false
35 );
36}
37?>