Revision 175
Added by ryan about 19 years ago
tool.php | ||
---|---|---|
25 | 25 |
|
26 | 26 |
require('../../config.php'); |
27 | 27 |
require_once(WB_PATH.'/framework/class.admin.php'); |
28 |
|
|
29 | 28 |
require_once(WB_PATH.'/framework/functions.php'); |
30 | 29 |
|
31 |
|
|
32 | 30 |
if(!isset($_GET['tool'])) { |
33 |
header("Location: index.php"); |
|
31 |
header("Location: index.php?advanced=yes");
|
|
34 | 32 |
} |
35 | 33 |
|
36 |
// check if tool is installed
|
|
37 |
$query_result=$database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'module' AND function = 'tool' AND name = '{$_GET['tool']}'");
|
|
38 |
if ($query_result->numRows()==0) {
|
|
39 |
header("Location: index.php"); |
|
34 |
// Check if tool is installed
|
|
35 |
$result = $database->query("SELECT * FROM ".TABLE_PREFIX."addons WHERE type = 'module' AND function = 'tool' AND directory = '".$_GET['tool']."'");
|
|
36 |
if($result->numRows() == 0) {
|
|
37 |
header("Location: index.php?advanced=yes");
|
|
40 | 38 |
} |
41 |
$tool=$query_result->fetchRow();
|
|
39 |
$tool = $result->fetchRow();
|
|
42 | 40 |
|
43 |
$admin = new admin("Tool: {$tool['name']}",'settings_advanced');
|
|
41 |
$admin = new admin('Settings', 'settings_advanced');
|
|
44 | 42 |
|
43 |
?> |
|
44 |
<h4 style="margin: 0; border-bottom: 1px solid #DDD; padding-bottom: 5px;"> |
|
45 |
<a href="<?php echo ADMIN_URL; ?>/settings/index.php?advanced=yes"><?php echo $MENU['SETTINGS']; ?></a> |
|
46 |
-> |
|
47 |
<a href="<?php echo ADMIN_URL; ?>/settings/index.php?advanced=yes#administration_tools"><?php echo $HEADING['ADMINISTRATION_TOOLS']; ?></a> |
|
48 |
-> |
|
49 |
<?php echo $tool['name']; ?> |
|
50 |
</h4> |
|
51 |
<?php |
|
45 | 52 |
require(WB_PATH.'/modules/'.$tool['directory'].'/tool.php'); |
46 | 53 |
|
47 | 54 |
$admin->print_footer(); |
48 |
?> |
|
55 |
|
|
56 |
?> |
Also available in: Unified diff
Updated tools interface