Commit b138793b authored by Dries's avatar Dries

- Patch #72079 by Earl et al: give Drupal an overall administration page ... :-)

parent 3a7b64ae
...@@ -2,6 +2,8 @@ ...@@ -2,6 +2,8 @@
Drupal x.x.x, xxxx-xx-xx (development version) Drupal x.x.x, xxxx-xx-xx (development version)
------------------------ ------------------------
- completely retooled the administration page
* /admin now contains an administration page which may be themed
- added web-based installer which can: - added web-based installer which can:
* automatically generate the database configuration file * automatically generate the database configuration file
* install pre-made 'install profiles' or distributions * install pre-made 'install profiles' or distributions
......
...@@ -86,7 +86,7 @@ function theme_locale_admin_manage_screen($form) { ...@@ -86,7 +86,7 @@ function theme_locale_admin_manage_screen($form) {
foreach ($form['name'] as $key => $element) { foreach ($form['name'] as $key => $element) {
// Do not take form control structures. // Do not take form control structures.
if (is_array($element) && element_child($key)) { if (is_array($element) && element_child($key)) {
$rows[] = array(check_plain($key), form_render($form['name'][$key]), form_render($form['enabled'][$key]), form_render($form['site_default'][$key]), ($key != 'en' ? form_render($form['translation'][$key]) : t('n/a')), ($key != 'en' ? l(t('delete'), 'admin/locale/language/delete/'. $key) : '')); $rows[] = array(check_plain($key), form_render($form['name'][$key]), form_render($form['enabled'][$key]), form_render($form['site_default'][$key]), ($key != 'en' ? form_render($form['translation'][$key]) : t('n/a')), ($key != 'en' ? l(t('delete'), 'admin/settings/locale/language/delete/'. $key) : ''));
} }
} }
$header = array(array('data' => t('Code')), array('data' => t('English name')), array('data' => t('Enabled')), array('data' => t('Default')), array('data' => t('Translated')), array('data' => t('Operations'))); $header = array(array('data' => t('Code')), array('data' => t('English name')), array('data' => t('Enabled')), array('data' => t('Default')), array('data' => t('Translated')), array('data' => t('Operations')));
...@@ -120,7 +120,7 @@ function _locale_admin_manage_screen_submit($form_id, $form_values) { ...@@ -120,7 +120,7 @@ function _locale_admin_manage_screen_submit($form_id, $form_values) {
// Changing the locale settings impacts the interface: // Changing the locale settings impacts the interface:
cache_clear_all(); cache_clear_all();
return 'admin/locale/language/overview'; return 'admin/settings/locale/language/overview';
} }
/** /**
...@@ -377,7 +377,7 @@ function _locale_string_edit($lid) { ...@@ -377,7 +377,7 @@ function _locale_string_edit($lid) {
// Handle erroneous lid. // Handle erroneous lid.
if (!isset($orig)){ if (!isset($orig)){
drupal_set_message(t('String not found.')); drupal_set_message(t('String not found.'));
drupal_goto('admin/locale/string/search'); drupal_goto('admin/settings/locale/string/search');
} }
// Add original text. Assign negative weight so that it floats to the top. // Add original text. Assign negative weight so that it floats to the top.
...@@ -424,7 +424,7 @@ function _locale_string_edit_submit($form_id, $form_values) { ...@@ -424,7 +424,7 @@ function _locale_string_edit_submit($form_id, $form_values) {
// Rebuild the menu, strings may have changed. // Rebuild the menu, strings may have changed.
menu_rebuild(); menu_rebuild();
return 'admin/locale/string/search'; return 'admin/settings/locale/string/search';
} }
/** /**
...@@ -436,7 +436,7 @@ function _locale_string_delete($lid) { ...@@ -436,7 +436,7 @@ function _locale_string_delete($lid) {
locale_refresh_cache(); locale_refresh_cache();
drupal_set_message(t('The string has been removed.')); drupal_set_message(t('The string has been removed.'));
drupal_goto('admin/locale/string/search'); drupal_goto('admin/settings/locale/string/search');
} }
/** /**
...@@ -1314,7 +1314,7 @@ function _locale_string_seek() { ...@@ -1314,7 +1314,7 @@ function _locale_string_seek() {
$arr[$locale->lid]['source'] = $locale->source; $arr[$locale->lid]['source'] = $locale->source;
} }
foreach ($arr as $lid => $value) { foreach ($arr as $lid => $value) {
$rows[] = array(array('data' => check_plain(truncate_utf8($value['source'], 150, FALSE, TRUE)) .'<br /><small>'. $value['location'] .'</small>'), array('data' => _locale_string_language_list($value['locales']), 'align' => 'center'), array('data' => l(t('edit'), "admin/locale/string/edit/$lid"), 'class' => 'nowrap'), array('data' => l(t('delete'), "admin/locale/string/delete/$lid"), 'class' => 'nowrap')); $rows[] = array(array('data' => check_plain(truncate_utf8($value['source'], 150, FALSE, TRUE)) .'<br /><small>'. $value['location'] .'</small>'), array('data' => _locale_string_language_list($value['locales']), 'align' => 'center'), array('data' => l(t('edit'), "admin/settings/locale/string/edit/$lid"), 'class' => 'nowrap'), array('data' => l(t('delete'), "admin/settings/locale/string/delete/$lid"), 'class' => 'nowrap'));
} }
$request = array(); $request = array();
......
...@@ -866,11 +866,11 @@ function menu_primary_links($start_level = 1, $pid = 0) { ...@@ -866,11 +866,11 @@ function menu_primary_links($start_level = 1, $pid = 0) {
} }
} }
// Special case - provide link to admin/menu if primary links is empty. // Special case - provide link to admin/build/menu if primary links is empty.
if (empty($links) && $start_level == 1 && $pid == variable_get('menu_primary_menu', 0)) { if (empty($links) && $start_level == 1 && $pid == variable_get('menu_primary_menu', 0)) {
$links['1-1'] = array( $links['1-1'] = array(
'title' => t('edit primary links'), 'title' => t('edit primary links'),
'href' => 'admin/menu' 'href' => 'admin/build/menu'
); );
} }
......
...@@ -674,3 +674,55 @@ html.js fieldset.collapsed legend a { ...@@ -674,3 +674,55 @@ html.js fieldset.collapsed legend a {
display: block; display: block;
padding: 1.5em 0 .5em; padding: 1.5em 0 .5em;
} }
/*
** Formatting for administration page -- this should probably be its own file
*/
div.admin-panel {
margin: 0px 0px 0px 0px;
padding: 5px 5px 15px 5px;
}
div.admin-panel .description {
margin: 0px 0px 3px;
padding: 2px 0 3px 0;
font-weight: normal;
text-align: left;
color: #999;
}
div.admin-panel .body {
padding: 0 4px 2px 8px;
background-color: #f4f4f4;
line-height: 1.2em;
}
div.admin-panel .head {
background-color: #6699CC;
color: #FFFFFF;
font-weight: bold;
font-size: 14px;
margin: 0px 0px 0px 0px;
padding: 4px 4px 4px 8px;
}
div.admin {
padding-top: 15px;
}
div.admin .left {
float: left;
width: 47%;
margin-left: 1em;
}
div.admin .right {
float: right;
width: 47%;
margin-right: 1em;
}
div.admin .expert-link {
text-align: right;
margin-right: 1em;
padding-right: 4px;
}
...@@ -13,7 +13,7 @@ function aggregator_help($section) { ...@@ -13,7 +13,7 @@ function aggregator_help($section) {
switch ($section) { switch ($section) {
case 'admin/help#aggregator': case 'admin/help#aggregator':
$output = '<p>'. t('The news aggregator is a powerful on-site RSS syndicator/news reader that can gather fresh content from news sites and weblogs around the web.') .'</p>'; $output = '<p>'. t('The news aggregator is a powerful on-site RSS syndicator/news reader that can gather fresh content from news sites and weblogs around the web.') .'</p>';
$output .= '<p>'. t('Users can view the latest news chronologically in the <a href="%aggregator">main news aggregator display</a> or by <a href="%aggregator-sources">source</a>. Administrators can add, edit and delete feeds and choose how often to check for newly updated news for each individual feed. Administrators can also tag individual feeds with categories, offering selective grouping of some feeds into separate displays. Listings of the latest news for individual sources or categorized sources can be enabled as blocks for display in the sidebar through the <a href="%admin-block">block administration page</a>. The news aggregator requires cron to check for the latest news from the sites to which you have subscribed. Drupal also provides a <a href="%aggregator-opml">machine-readable OPML file</a> of all of your subscribed feeds.', array('%aggregator' => url('aggregator'), '%aggregator-sources' => url('aggregator/sources'), '%admin-block' => url('admin/block'), '%aggregator-opml' => url('aggregator/opml'))) .'</p>'; $output .= '<p>'. t('Users can view the latest news chronologically in the <a href="%aggregator">main news aggregator display</a> or by <a href="%aggregator-sources">source</a>. Administrators can add, edit and delete feeds and choose how often to check for newly updated news for each individual feed. Administrators can also tag individual feeds with categories, offering selective grouping of some feeds into separate displays. Listings of the latest news for individual sources or categorized sources can be enabled as blocks for display in the sidebar through the <a href="%admin-block">block administration page</a>. The news aggregator requires cron to check for the latest news from the sites to which you have subscribed. Drupal also provides a <a href="%aggregator-opml">machine-readable OPML file</a> of all of your subscribed feeds.', array('%aggregator' => url('aggregator'), '%aggregator-sources' => url('aggregator/sources'), '%admin-block' => url('admin/build/block'), '%aggregator-opml' => url('aggregator/opml'))) .'</p>';
$output .= t('<p>You can</p> $output .= t('<p>You can</p>
<ul> <ul>
<li>administer your list of news feeds <a href="%admin-aggregator">administer &gt;&gt; aggregator</a>.</li> <li>administer your list of news feeds <a href="%admin-aggregator">administer &gt;&gt; aggregator</a>.</li>
...@@ -24,16 +24,16 @@ function aggregator_help($section) { ...@@ -24,16 +24,16 @@ function aggregator_help($section) {
<li>set permissions to access new feeds for user roles such as anonymous users at <a href="%admin-access">administer &gt;&gt; access control</a>.</li> <li>set permissions to access new feeds for user roles such as anonymous users at <a href="%admin-access">administer &gt;&gt; access control</a>.</li>
<li>view the <a href="%aggregator">aggregator page</a>.</li> <li>view the <a href="%aggregator">aggregator page</a>.</li>
</ul> </ul>
', array('%admin-aggregator' => url('admin/aggregator'), '%admin-aggregator-add-feed' => url('admin/aggregator/add/feed'), '%admin-aggregator-add-category' => url('admin/aggregator/add/category'), '%admin-settings-aggregator' => url('admin/settings/aggregator'), '%admin-access' => url('admin/access'), '%aggregator' => url('aggregator'))); ', array('%admin-aggregator' => url('admin/content/aggregator'), '%admin-aggregator-add-feed' => url('admin/content/aggregator/add/feed'), '%admin-aggregator-add-category' => url('admin/content/aggregator/add/category'), '%admin-settings-aggregator' => url('admin/settings/aggregator'), '%admin-access' => url('admin/access'), '%aggregator' => url('aggregator')));
$output .= '<p>'. t('For more information please read the configuration and customization handbook <a href="%aggregator">Aggregator page</a>.', array('%aggregator' => 'http://drupal.org/handbook/modules/aggregator/')) .'</p>'; $output .= '<p>'. t('For more information please read the configuration and customization handbook <a href="%aggregator">Aggregator page</a>.', array('%aggregator' => 'http://drupal.org/handbook/modules/aggregator/')) .'</p>';
return $output; return $output;
case 'admin/modules#description': case 'admin/settings/modules#description':
return t('Aggregates syndicated content (RSS, RDF, and Atom feeds).'); return t('Aggregates syndicated content (RSS, RDF, and Atom feeds).');
case 'admin/aggregator': case 'admin/content/aggregator':
return t('<p>Thousands of sites (particularly news sites and weblogs) publish their latest headlines and/or stories in a machine-readable format so that other sites can easily link to them. This content is usually in the form of an <a href="http://blogs.law.harvard.edu/tech/rss">RSS</a> feed (which is an XML-based syndication standard). To display the feed or category in a block you must decide how many items to show by editing the feed or block and turning on the <a href="%block">feed\'s block</a>.</p>', array('%block' => url('admin/block'))); return t('<p>Thousands of sites (particularly news sites and weblogs) publish their latest headlines and/or stories in a machine-readable format so that other sites can easily link to them. This content is usually in the form of an <a href="http://blogs.law.harvard.edu/tech/rss">RSS</a> feed (which is an XML-based syndication standard). To display the feed or category in a block you must decide how many items to show by editing the feed or block and turning on the <a href="%block">feed\'s block</a>.</p>', array('%block' => url('admin/build/block')));
case 'admin/aggregator/add/feed': case 'admin/content/aggregator/add/feed':
return t('<p>Add a site that has an RSS/RDF/Atom feed. The URL is the full path to the feed file. For the feed to update automatically you must run "cron.php" on a regular basis. If you already have a feed with the URL you are planning to use, the system will not accept another feed with the same URL.</p>'); return t('<p>Add a site that has an RSS/RDF/Atom feed. The URL is the full path to the feed file. For the feed to update automatically you must run "cron.php" on a regular basis. If you already have a feed with the URL you are planning to use, the system will not accept another feed with the same URL.</p>');
case 'admin/aggregator/add/category': case 'admin/content/aggregator/add/category':
return t('<p>Categories provide a way to group items from different news feeds together. Each news category has its own feed page and block. For example, you could tag various sport-related feeds as belonging to a category called <em>Sports</em>. News items can be added to a category automatically by setting a feed to automatically place its item into that category, or by using the categorize items link in any listing of news items.</p>'); return t('<p>Categories provide a way to group items from different news feeds together. Each news category has its own feed page and block. For example, you could tag various sport-related feeds as belonging to a category called <em>Sports</em>. News items can be added to a category automatically by setting a feed to automatically place its item into that category, or by using the categorize items link in any listing of news items.</p>');
} }
} }
...@@ -47,38 +47,40 @@ function aggregator_menu($may_cache) { ...@@ -47,38 +47,40 @@ function aggregator_menu($may_cache) {
$view = user_access('access news feeds'); $view = user_access('access news feeds');
if ($may_cache) { if ($may_cache) {
$items[] = array('path' => 'admin/aggregator', $items[] = array('path' => 'admin/content/aggregator',
'title' => t('aggregator'), 'title' => t('RSS aggregator'),
'description' => t('Configure which content your site aggregates from other sites, how often it polls them, and how they\'re categorized.'),
'callback' => 'aggregator_admin_overview', 'callback' => 'aggregator_admin_overview',
'access' => $edit); 'access' => $edit);
$items[] = array('path' => 'admin/aggregator/add/feed', $items[] = array('path' => 'admin/content/aggregator/add/feed',
'title' => t('add feed'), 'title' => t('add feed'),
'callback' => 'aggregator_form_feed', 'callback' => 'aggregator_form_feed',
'access' => $edit, 'access' => $edit,
'type' => MENU_LOCAL_TASK); 'type' => MENU_LOCAL_TASK);
$items[] = array('path' => 'admin/aggregator/add/category', $items[] = array('path' => 'admin/content/aggregator/add/category',
'title' => t('add category'), 'title' => t('add category'),
'callback' => 'aggregator_form_category', 'callback' => 'aggregator_form_category',
'access' => $edit, 'access' => $edit,
'type' => MENU_LOCAL_TASK); 'type' => MENU_LOCAL_TASK);
$items[] = array('path' => 'admin/aggregator/remove', $items[] = array('path' => 'admin/content/aggregator/remove',
'title' => t('remove items'), 'title' => t('remove items'),
'callback' => 'aggregator_admin_remove_feed', 'callback' => 'aggregator_admin_remove_feed',
'access' => $edit, 'access' => $edit,
'type' => MENU_CALLBACK); 'type' => MENU_CALLBACK);
$items[] = array('path' => 'admin/aggregator/update', $items[] = array('path' => 'admin/content/aggregator/update',
'title' => t('update items'), 'title' => t('update items'),
'callback' => 'aggregator_admin_refresh_feed', 'callback' => 'aggregator_admin_refresh_feed',
'access' => $edit, 'access' => $edit,
'type' => MENU_CALLBACK); 'type' => MENU_CALLBACK);
$items[] = array('path' => 'admin/aggregator/list', $items[] = array('path' => 'admin/content/aggregator/list',
'title' => t('list'), 'title' => t('list'),
'type' => MENU_DEFAULT_LOCAL_TASK, 'type' => MENU_DEFAULT_LOCAL_TASK,
'weight' => -10); 'weight' => -10);
$items[] = array('path' => 'admin/settings/aggregator', $items[] = array('path' => 'admin/content/aggregator/settings',
'title' => t('RSS aggregator'), 'title' => t('settings'),
'callback' => 'aggregator_admin_settings', 'callback' => 'aggregator_admin_settings',
'type' => MENU_NORMAL_ITEM, 'type' => MENU_LOCAL_TASK,
'weight' => 10,
'access' => $edit); 'access' => $edit);
$items[] = array('path' => 'aggregator', $items[] = array('path' => 'aggregator',
...@@ -168,7 +170,7 @@ function aggregator_menu($may_cache) { ...@@ -168,7 +170,7 @@ function aggregator_menu($may_cache) {
if (arg(3) == 'feed') { if (arg(3) == 'feed') {
$feed = aggregator_get_feed(arg(4)); $feed = aggregator_get_feed(arg(4));
if ($feed) { if ($feed) {
$items[] = array('path' => 'admin/aggregator/edit/feed/'. $feed['fid'], $items[] = array('path' => 'admin/content/aggregator/edit/feed/'. $feed['fid'],
'title' => t('edit feed'), 'title' => t('edit feed'),
'callback' => 'aggregator_form_feed', 'callback' => 'aggregator_form_feed',
'callback arguments' => array($feed), 'callback arguments' => array($feed),
...@@ -179,7 +181,7 @@ function aggregator_menu($may_cache) { ...@@ -179,7 +181,7 @@ function aggregator_menu($may_cache) {
else { else {
$category = aggregator_get_category(arg(4)); $category = aggregator_get_category(arg(4));
if ($category) { if ($category) {
$items[] = array('path' => 'admin/aggregator/edit/category/'. $category['cid'], $items[] = array('path' => 'admin/content/aggregator/edit/category/'. $category['cid'],
'title' => t('edit category'), 'title' => t('edit category'),
'callback' => 'aggregator_form_category', 'callback' => 'aggregator_form_category',
'callback arguments' => array($category), 'callback arguments' => array($category),
...@@ -367,7 +369,7 @@ function aggregator_form_category_submit($form_id, $form_values) { ...@@ -367,7 +369,7 @@ function aggregator_form_category_submit($form_id, $form_values) {
if (isset($form_values['title'])) { if (isset($form_values['title'])) {
drupal_set_message(t('The category %category has been updated.', array('%category' => theme('placeholder', $form_values['title'])))); drupal_set_message(t('The category %category has been updated.', array('%category' => theme('placeholder', $form_values['title']))));
if (arg(0) == 'admin') { if (arg(0) == 'admin') {
return 'admin/aggregator/'; return 'admin/content/aggregator/';
} }
else { else {
return 'aggregator/categories/'. $form_values['cid']; return 'aggregator/categories/'. $form_values['cid'];
...@@ -377,7 +379,7 @@ function aggregator_form_category_submit($form_id, $form_values) { ...@@ -377,7 +379,7 @@ function aggregator_form_category_submit($form_id, $form_values) {
watchdog('aggregator', t('Category %category deleted.', array('%category' => theme('placeholder', $title)))); watchdog('aggregator', t('Category %category deleted.', array('%category' => theme('placeholder', $title))));
drupal_set_message(t('The category %category has been deleted.', array('%category' => theme('placeholder', $title)))); drupal_set_message(t('The category %category has been deleted.', array('%category' => theme('placeholder', $title))));
if (arg(0) == 'admin') { if (arg(0) == 'admin') {
return 'admin/aggregator/'; return 'admin/content/aggregator/';
} }
else { else {
return 'aggregator/categories/'; return 'aggregator/categories/';
...@@ -385,7 +387,7 @@ function aggregator_form_category_submit($form_id, $form_values) { ...@@ -385,7 +387,7 @@ function aggregator_form_category_submit($form_id, $form_values) {
} }
} }
else { else {
watchdog('aggregator', t('Category %category added.', array('%category' => theme('placeholder', $form_values['title']))), WATCHDOG_NOTICE, l(t('view'), 'admin/aggregator')); watchdog('aggregator', t('Category %category added.', array('%category' => theme('placeholder', $form_values['title']))), WATCHDOG_NOTICE, l(t('view'), 'admin/content/aggregator'));
drupal_set_message(t('The category %category has been added.', array('%category' => theme('placeholder', $form_values['title'])))); drupal_set_message(t('The category %category has been added.', array('%category' => theme('placeholder', $form_values['title']))));
} }
} }
...@@ -500,7 +502,7 @@ function aggregator_form_feed_submit($form_id, $form_values) { ...@@ -500,7 +502,7 @@ function aggregator_form_feed_submit($form_id, $form_values) {
if (isset($form_values['title'])) { if (isset($form_values['title'])) {
drupal_set_message(t('The feed %feed has been updated.', array('%feed' => theme('placeholder', $form_values['title'])))); drupal_set_message(t('The feed %feed has been updated.', array('%feed' => theme('placeholder', $form_values['title']))));
if (arg(0) == 'admin') { if (arg(0) == 'admin') {
return 'admin/aggregator/'; return 'admin/content/aggregator/';
} }
else { else {
return 'aggregator/sources/'. $form_values['fid']; return 'aggregator/sources/'. $form_values['fid'];
...@@ -510,7 +512,7 @@ function aggregator_form_feed_submit($form_id, $form_values) { ...@@ -510,7 +512,7 @@ function aggregator_form_feed_submit($form_id, $form_values) {
watchdog('aggregator', t('Feed %feed deleted.', array('%feed' => theme('placeholder', $title)))); watchdog('aggregator', t('Feed %feed deleted.', array('%feed' => theme('placeholder', $title))));
drupal_set_message(t('The feed %feed has been deleted.', array('%feed' => theme('placeholder', $title)))); drupal_set_message(t('The feed %feed has been deleted.', array('%feed' => theme('placeholder', $title))));
if (arg(0) == 'admin') { if (arg(0) == 'admin') {
return 'admin/aggregator/'; return 'admin/content/aggregator/';
} }
else { else {
return 'aggregator/sources/'; return 'aggregator/sources/';
...@@ -518,7 +520,7 @@ function aggregator_form_feed_submit($form_id, $form_values) { ...@@ -518,7 +520,7 @@ function aggregator_form_feed_submit($form_id, $form_values) {
} }
} }
else { else {
watchdog('aggregator', t('Feed %feed added.', array('%feed' => theme('placeholder', $form_values['title']))), WATCHDOG_NOTICE, l(t('view'), 'admin/aggregator')); watchdog('aggregator', t('Feed %feed added.', array('%feed' => theme('placeholder', $form_values['title']))), WATCHDOG_NOTICE, l(t('view'), 'admin/content/aggregator'));
drupal_set_message(t('The feed %feed has been added.', array('%feed' => theme('placeholder', $form_values['title'])))); drupal_set_message(t('The feed %feed has been added.', array('%feed' => theme('placeholder', $form_values['title']))));
} }
} }
...@@ -974,7 +976,7 @@ function aggregator_view() { ...@@ -974,7 +976,7 @@ function aggregator_view() {
$header = array(t('Title'), t('Items'), t('Last update'), t('Next update'), array('data' => t('Operations'), 'colspan' => '3')); $header = array(t('Title'), t('Items'), t('Last update'), t('Next update'), array('data' => t('Operations'), 'colspan' => '3'));
$rows = array(); $rows = array();
while ($feed = db_fetch_object($result)) { while ($feed = db_fetch_object($result)) {
$rows[] = array(l($feed->title, "aggregator/sources/$feed->fid"), format_plural($feed->items, '1 item', '%count items'), ($feed->checked ? t('%time ago', array('%time' => format_interval(time() - $feed->checked))) : t('never')), ($feed->checked ? t('%time left', array('%time' => format_interval($feed->checked + $feed->refresh - time()))) : t('never')), l(t('edit'), "admin/aggregator/edit/feed/$feed->fid"), l(t('remove items'), "admin/aggregator/remove/$feed->fid"), l(t('update items'), "admin/aggregator/update/$feed->fid")); $rows[] = array(l($feed->title, "aggregator/sources/$feed->fid"), format_plural($feed->items, '1 item', '%count items'), ($feed->checked ? t('%time ago', array('%time' => format_interval(time() - $feed->checked))) : t('never')), ($feed->checked ? t('%time left', array('%time' => format_interval($feed->checked + $feed->refresh - time()))) : t('never')), l(t('edit'), "admin/content/aggregator/edit/feed/$feed->fid"), l(t('remove items'), "admin/content/aggregator/remove/$feed->fid"), l(t('update items'), "admin/content/aggregator/update/$feed->fid"));
} }
$output .= theme('table', $header, $rows); $output .= theme('table', $header, $rows);
...@@ -985,7 +987,7 @@ function aggregator_view() { ...@@ -985,7 +987,7 @@ function aggregator_view() {
$header = array(t('Title'), t('Items'), t('Operations')); $header = array(t('Title'), t('Items'), t('Operations'));
$rows = array(); $rows = array();
while ($category = db_fetch_object($result)) { while ($category = db_fetch_object($result)) {
$rows[] = array(l($category->title, "aggregator/categories/$category->cid"), format_plural($category->items, '1 item', '%count items'), l(t('edit'), "admin/aggregator/edit/category/$category->cid")); $rows[] = array(l($category->title, "aggregator/categories/$category->cid"), format_plural($category->items, '1 item', '%count items'), l(t('edit'), "admin/content/aggregator/edit/category/$category->cid"));
} }
$output .= theme('table', $header, $rows); $output .= theme('table', $header, $rows);
...@@ -997,7 +999,7 @@ function aggregator_view() { ...@@ -997,7 +999,7 @@ function aggregator_view() {
*/ */
function aggregator_admin_remove_feed($feed) { function aggregator_admin_remove_feed($feed) {
aggregator_remove(aggregator_get_feed($feed)); aggregator_remove(aggregator_get_feed($feed));
drupal_goto('admin/aggregator'); drupal_goto('admin/content/aggregator');
} }
/** /**
...@@ -1005,7 +1007,7 @@ function aggregator_admin_remove_feed($feed) { ...@@ -1005,7 +1007,7 @@ function aggregator_admin_remove_feed($feed) {
*/ */
function aggregator_admin_refresh_feed($feed) { function aggregator_admin_refresh_feed($feed) {
aggregator_refresh(aggregator_get_feed($feed)); aggregator_refresh(aggregator_get_feed($feed));
drupal_goto('admin/aggregator'); drupal_goto('admin/content/aggregator');
} }
/** /**
...@@ -1290,7 +1292,7 @@ function theme_aggregator_feed($feed) { ...@@ -1290,7 +1292,7 @@ function theme_aggregator_feed($feed) {
} }
if (user_access('administer news feeds')) { if (user_access('administer news feeds')) {
$updated = l($updated, 'admin/aggregator'); $updated = l($updated, 'admin/content/aggregator');
} }
$output .= '<div class="feed-updated"><em>'. t('Updated:') . "</em> $updated</div>"; $output .= '<div class="feed-updated"><em>'. t('Updated:') . "</em> $updated</div>";
......
...@@ -19,10 +19,10 @@ function archive_help($section) { ...@@ -19,10 +19,10 @@ function archive_help($section) {
<li>view your <a href="%archive">archive by day</a>.</li> <li>view your <a href="%archive">archive by day</a>.</li>
<li>enable the <em>browse archives</em> block at <a href="%admin-block">administer &gt;&gt; block</a>.</li> <li>enable the <em>browse archives</em> block at <a href="%admin-block">administer &gt;&gt; block</a>.</li>
</ul> </ul>
', array('%archive' => url('archive'), '%admin-block' => url('admin/block'))); ', array('%archive' => url('archive'), '%admin-block' => url('admin/build/block')));
$output .= '<p>'. t('For more information please read the configuration and customization handbook <a href="%archive">Archive page</a>.', array('%archive' => 'http://drupal.org/handbook/modules/archive/')) .'</p>'; $output .= '<p>'. t('For more information please read the configuration and customization handbook <a href="%archive">Archive page</a>.', array('%archive' => 'http://drupal.org/handbook/modules/archive/')) .'</p>';
return $output; return $output;
case 'admin/modules#description': case 'admin/settings/modules#description':
return t('Displays a calendar for navigating older content.'); return t('Displays a calendar for navigating older content.');
} }
} }
......
...@@ -27,7 +27,7 @@ function block_help($section) { ...@@ -27,7 +27,7 @@ function block_help($section) {
</ul> </ul>
'); ');
$output .= '<h3>'. t('Module blocks') .'</h3>'; $output .= '<h3>'. t('Module blocks') .'</h3>';
$output .= '<p>'. t('Some modules generate blocks that become available when the modules are enabled. These blocks can be administered via the <a href="%admin-block">blocks administration page</a>.</p>', array('%admin-block' => url('admin/block'))) .'</p>'; $output .= '<p>'. t('Some modules generate blocks that become available when the modules are enabled. These blocks can be administered via the <a href="%admin-block">blocks administration page</a>.</p>', array('%admin-block' => url('admin/build/block'))) .'</p>';
$output .= '<h3>'. t('Administrator defined blocks') .'</h3>'; $output .= '<h3>'. t('Administrator defined blocks') .'</h3>';
$output .= '<p>'. t('Administrators can also define custom blocks. These blocks consist of a title, a description, and a body which can be as long as you wish. Block content can be in any of the input formats supported for other content.') .'</p>'; $output .= '<p>'. t('Administrators can also define custom blocks. These blocks consist of a title, a description, and a body which can be as long as you wish. Block content can be in any of the input formats supported for other content.') .'</p>';
$output .= t('<p>You can</p> $output .= t('<p>You can</p>
...@@ -35,20 +35,20 @@ function block_help($section) { ...@@ -35,20 +35,20 @@ function block_help($section) {
<li>enable, throttle and configure blocks at <a href="%admin-block">administer &gt;&gt; blocks</a>.</li> <li>enable, throttle and configure blocks at <a href="%admin-block">administer &gt;&gt; blocks</a>.</li>
<li>add an administrator-defined block at <a href="%admin-block-add">administer &gt;&gt; blocks &gt;&gt; add block</a>.</li> <li>add an administrator-defined block at <a href="%admin-block-add">administer &gt;&gt; blocks &gt;&gt; add block</a>.</li>
</ul> </ul>
', array('%admin-block' => url('admin/block'), '%admin-block-add' => url('admin/block/add'))); ', array('%admin-block' => url('admin/build/block'), '%admin-block-add' => url('admin/build/block/add')));
$output .= '<p>'. t('For more information please read the configuration and customization handbook <a href="%block">Block page</a>.', array('%block' => 'http://drupal.org/handbook/modules/block/')) .'</p>'; $output .= '<p>'. t('For more information please read the configuration and customization handbook <a href="%block">Block page</a>.', array('%block' => 'http://drupal.org/handbook/modules/block/')) .'</p>';
return $output; return $output;
case 'admin/modules#description': case 'admin/settings/modules#description':
return t('Controls the boxes that are displayed around the main content.'); return t('Controls the boxes that are displayed around the main content.');
case 'admin/block': case 'admin/build/block':
return t(" return t("
<p>Blocks are boxes of content that may be rendered into certain regions of your web pages, for example, into sidebars. They are usually generated automatically by modules, but administrators can create blocks manually.</p> <p>Blocks are boxes of content that may be rendered into certain regions of your web pages, for example, into sidebars. They are usually generated automatically by modules, but administrators can create blocks manually.</p>
<p>Only enabled blocks are shown. You can position blocks by specifying which area of the page they should appear in (e.g., a sidebar). Highlighted labels on this page show the regions into which blocks can be rendered. You can specify where within a region a block will appear by adjusting its weight.</p> <p>Only enabled blocks are shown. You can position blocks by specifying which area of the page they should appear in (e.g., a sidebar). Highlighted labels on this page show the regions into which blocks can be rendered. You can specify where within a region a block will appear by adjusting its weight.</p>
<p>If you want certain blocks to disable themselves temporarily during high server loads, check the 'Throttle' box. You can configure the auto-throttle on the <a href=\"%throttle\">throttle configuration page</a> after having enabled the throttle module.</p> <p>If you want certain blocks to disable themselves temporarily during high server loads, check the 'Throttle' box. You can configure the auto-throttle on the <a href=\"%throttle\">throttle configuration page</a> after having enabled the throttle module.</p>
<p>You can configure the behaviour of each block (for example, specifying on which pages and for what users it will appear) by clicking the 'configure' link for each block.</p> <p>You can configure the behaviour of each block (for example, specifying on which pages and for what users it will appear) by clicking the 'configure' link for each block.</p>
", array('%throttle' => url('admin/settings/throttle'))); ", array('%throttle' => url('admin/settings/throttle')));
case 'admin/block/add': case 'admin/build/block/add':
return t('<p>Here you can create a new block. Once you have created this block you must make it active and give it a place on the page using <a href="%overview">blocks</a>. The title is used when displaying the block. The description is used in the "block" column on the <a href="%overview">blocks</a> page.</p>', array('%overview' => url('admin/block'))); return t('<p>Here you can create a new block. Once you have created this block you must make it active and give it a place on the page using <a href="%overview">blocks</a>. The title is used when displaying the block. The description is used in the "block" column on the <a href="%overview">blocks</a> page.</p>', array('%overview' => url('admin/build/block')));
} }
} }
...@@ -66,31 +66,34 @@ function block_menu($may_cache) { ...@@ -66,31 +66,34 @@ function block_menu($may_cache) {
$items = array(); $items = array();
if ($may_cache) { if ($may_cache) {
$items[] = array('path' => 'admin/block', 'title' => t('blocks'), $items[] = array(
'path' => 'admin/build/block',
'title' => t('blocks'),
'access' => user_access('administer blocks'), 'access' => user_access('administer blocks'),
'description' => t('Configure what block content appears in your site\'s sidebars and other regions.'),
'callback' => 'block_admin_display'); 'callback' => 'block_admin_display');
$items[] = array('path' => 'admin/block/list', 'title' => t('list'), $items[] = array('path' => 'admin/build/block/list', 'title' => t('list'),
'type' => MENU_DEFAULT_LOCAL_TASK, 'weight' => -10); 'type' => MENU_DEFAULT_LOCAL_TASK, 'weight' => -10);
$items[] = array('path' => 'admin/block/configure', 'title' => t('configure block'), $items[] = array('path' => 'admin/build/block/configure', 'title' => t('configure block'),
'access' => user_access('administer blocks'), 'access' => user_access('administer blocks'),
'callback' => 'block_admin_configure', 'callback' => 'block_admin_configure',
'type' => MENU_CALLBACK); 'type' => MENU_CALLBACK);
$items[] = array('path' => 'admin/block/delete', 'title' => t('delete block'), $items[] = array('path' => 'admin/build/block/delete', 'title' => t('delete block'),
'access' => user_access('administer blocks'), 'access' => user_access('administer blocks'),
'callback' => 'block_box_delete', 'callback' => 'block_box_delete',
'type' => MENU_CALLBACK); 'type' => MENU_CALLBACK);
$items[] = array('path' => 'admin/block/add', 'title' => t('add block'), $items[] = array('path' => 'admin/build/block/add', 'title' => t('add block'),
'access' => user_access('administer blocks'), 'access' => user_access('administer blocks'),
'callback' => 'block_box_add', 'callback' => 'block_box_add',
'type' => MENU_LOCAL_TASK); 'type' => MENU_LOCAL_TASK);
foreach (list_themes() as $key => $theme) { foreach (list_themes() as $key => $theme) {
if ($theme->status) { if ($theme->status) {
if ($key == variable_get('theme_default', 'bluemarine')) { if ($key == variable_get