blob: 3b48e3e21f42b974ce474a17a8a0b17ea11a65ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
<?php
// $Id$
include_once "includes/common.inc";
function status($message) {
if ($message) {
return "<b>Status:</b> $message<hr />\n";
}
}
function admin_link($type) {
if ($type == "admin") {
menu("admin/sitemap", "sitemap", "sitemap_callback", NULL, 8);
}
}
function sitemap_callback() {
return menu_map('admin');
}
function admin_admin() {
print menu_map();
}
function admin_page() {
global $user, $base_url;
if (user_access("access administration pages")) {
page_header();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
<html>
<head>
<title><?php echo variable_get("site_name", "drupal") . " " . t("administration pages"); ?></title>
<base href="<?php echo "$base_url/" ?>" />
<link rel="stylesheet" type="text/css" media="print" href="misc/print.css" />
<style type="text/css" title="layout" media="Screen">
@import url("misc/admin.css");
</style>
</head>
<body>
<?php
// NOTE: we include a dummy "print.css" to remove the "flash of unstyled content" (FUOC) problems in IE.
module_invoke_all("link", "admin");
/*
** Menu:
*/
print "<div id=\"menu\">";
echo "<h1><a href=\"index.php\">". variable_get("site_name", "drupal") ."</a></h1>";
//print menu_tree('admin') ;
print menu_tree('admin') ;
print "</div>";
/*
** Body:
*/
print "<a href=\"http://drupal.org/\"><img align=\"right\" src=\"misc/druplicon-small.gif\" alt=\"Druplicon - Drupal logo\" border=\"0\" /></a>";
print "<div id=\"main\">";
if ($path = menu_path()) {
print "<h2>". l(t("Administration"), "admin") ." $path</h2>";
}
else {
print "<h2>". t("Administration") ."</h2>";
}
/*
if ($menu = menu_menu()) {
print "$menu<br />";
}
*/
if ($help = menu_help()) {
print "<small>$help</small>";
}
print "<hr />";
if (arg(1)) {
//print module_invoke(arg(1), "admin");
print menu_execute_action();
}
else {
print "<h2>". t("System messages") ."</h2>";
print watchdog_overview("actions");
}
print "</div>";
?>
</body>
</html>
<?php
page_footer();
}
else {
print message_access();
}
}
?>
|