Commit d24d9544 authored by Dries's avatar Dries

- Patch #521474 by bangpound, JuliaKM et al: rename admin/site-building to admin/structure.

parent 999d76e7
......@@ -262,8 +262,8 @@ few active modules and minimal user access rights.
Use your administration panel to enable and configure services. For example:
General Settings Administer > Site configuration > Site information
Enable Modules Administer > Site building > Modules
Configure Themes Administer > Site building > Themes
Enable Modules Administer > Structure > Modules
Configure Themes Administer > Structure > Themes
Set User Permissions Administer > User management > Permissions
For more information on configuration options, read the instructions which
......
......@@ -169,7 +169,7 @@ function actions_list($reset = FALSE) {
*
* Compare with actions_list() which gathers actions by invoking
* hook_action_info(). The two are synchronized by visiting
* /admin/build/actions (when actions.module is enabled) which runs
* /admin/structure/actions (when actions.module is enabled) which runs
* actions_synchronize().
*
* @return
......
......@@ -3145,7 +3145,7 @@ function drupal_get_library($module, $name) {
* @endcode
*
* In a more complex case where there are several groups in one column (such as
* the block regions on the admin/build/block page), a separate subgroup class
* the block regions on the admin/structure/block page), a separate subgroup class
* must also be added to differentiate the groups.
* @code
* $form['my_elements'][$region][$delta]['weight']['#attributes']['class'] = "my-elements-weight my-elements-weight-" . $region;
......
......@@ -506,7 +506,7 @@ function drupal_install_modules($module_list = array(), $disable_modules_install
*
* Used during installation to install modules one at a time and then
* enable them, or to install a number of modules at one time
* from admin/build/modules.
* from admin/structure/modules.
*
* @param $module
* The machine name of the module to install.
......
......@@ -223,7 +223,7 @@ function drupal_get_normal_path($path, $path_language = '') {
/**
* Return a component of the current Drupal path.
*
* When viewing a page at the path "admin/build/types", for example, arg(0)
* When viewing a page at the path "admin/structure/types", for example, arg(0)
* returns "admin", arg(1) returns "content", and arg(2) returns "types".
*
* Avoid use of this function where possible, as resulting code is hard to read.
......
......@@ -86,7 +86,7 @@ function aggregator_form_feed(&$form_state, stdClass $feed = NULL) {
'#title' => t('News items in block'),
'#default_value' => isset($feed->block) ? $feed->block : 5,
'#options' => drupal_map_assoc(array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20)),
'#description' => t("Drupal can make a block with the most recent news items of this feed. You can <a href=\"@block-admin\">configure blocks</a> to be displayed in the sidebar of your page. This setting lets you configure the number of news items to show in this feed's block. If you choose '0' this feed's block will be disabled.", array('@block-admin' => url('admin/build/block'))),
'#description' => t("Drupal can make a block with the most recent news items of this feed. You can <a href=\"@block-admin\">configure blocks</a> to be displayed in the sidebar of your page. This setting lets you configure the number of news items to show in this feed's block. If you choose '0' this feed's block will be disabled.", array('@block-admin' => url('admin/structure/block'))),
);
// Handling of categories.
......@@ -255,7 +255,7 @@ function aggregator_form_opml(&$form_state) {
'#title' => t('News items in block'),
'#default_value' => 5,
'#options' => drupal_map_assoc(array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20)),
'#description' => t("Drupal can make a block with the most recent news items of a feed. You can <a href=\"@block-admin\">configure blocks</a> to be displayed in the sidebar of your page. This setting lets you configure the number of news items to show in a feed's block. If you choose '0' these feeds' blocks will be disabled.", array('@block-admin' => url('admin/build/block'))),
'#description' => t("Drupal can make a block with the most recent news items of a feed. You can <a href=\"@block-admin\">configure blocks</a> to be displayed in the sidebar of your page. This setting lets you configure the number of news items to show in a feed's block. If you choose '0' these feeds' blocks will be disabled.", array('@block-admin' => url('admin/structure/block'))),
);
// Handling of categories.
......
......@@ -18,12 +18,12 @@ function aggregator_help($path, $arg) {
switch ($path) {
case 'admin/help#aggregator':
$output = '<p>' . t('The aggregator is a powerful on-site syndicator and news reader that gathers fresh content from RSS-, RDF-, and Atom-based feeds made available across the web. Thousands of sites (particularly news sites and blogs) publish their latest headlines and posts in feeds, using a number of standardized XML-based formats. Formats supported by the aggregator include <a href="@rss">RSS</a>, <a href="@rdf">RDF</a>, and <a href="@atom">Atom</a>.', array('@rss' => 'http://cyber.law.harvard.edu/rss/', '@rdf' => 'http://www.w3.org/RDF/', '@atom' => 'http://www.atomenabled.org')) . '</p>';
$output .= '<p>' . t('Feeds contain feed items, or individual posts published by the site providing the feed. Feeds may be grouped in categories, generally by topic. Users view feed items in the <a href="@aggregator">main aggregator display</a> or by <a href="@aggregator-sources">their source</a>. Administrators can <a href="@feededit">add, edit and delete feeds</a> and choose how often to check each feed for newly updated items. The most recent items in either a feed or category can be displayed as a block through the <a href="@admin-block">blocks administration page</a>. A <a href="@aggregator-opml">machine-readable OPML file</a> of all feeds is available. A correctly configured <a href="@cron">cron maintenance task</a> is required to update feeds automatically.', array('@aggregator' => url('aggregator'), '@aggregator-sources' => url('aggregator/sources'), '@feededit' => url('admin/content/aggregator'), '@admin-block' => url('admin/build/block'), '@aggregator-opml' => url('aggregator/opml'), '@cron' => url('admin/reports/status'))) . '</p>';
$output .= '<p>' . t('Feeds contain feed items, or individual posts published by the site providing the feed. Feeds may be grouped in categories, generally by topic. Users view feed items in the <a href="@aggregator">main aggregator display</a> or by <a href="@aggregator-sources">their source</a>. Administrators can <a href="@feededit">add, edit and delete feeds</a> and choose how often to check each feed for newly updated items. The most recent items in either a feed or category can be displayed as a block through the <a href="@admin-block">blocks administration page</a>. A <a href="@aggregator-opml">machine-readable OPML file</a> of all feeds is available. A correctly configured <a href="@cron">cron maintenance task</a> is required to update feeds automatically.', array('@aggregator' => url('aggregator'), '@aggregator-sources' => url('aggregator/sources'), '@feededit' => url('admin/content/aggregator'), '@admin-block' => url('admin/structure/block'), '@aggregator-opml' => url('aggregator/opml'), '@cron' => url('admin/reports/status'))) . '</p>';
$output .= '<p>' . t('For more information, see the online handbook entry for <a href="@aggregator">Aggregator module</a>.', array('@aggregator' => 'http://drupal.org/handbook/modules/aggregator/')) . '</p>';
return $output;
case 'admin/content/aggregator':
$output = '<p>' . t('Thousands of sites (particularly news sites and blogs) publish their latest headlines and posts in feeds, using a number of standardized XML-based formats. Formats supported by the aggregator include <a href="@rss">RSS</a>, <a href="@rdf">RDF</a>, and <a href="@atom">Atom</a>.', array('@rss' => 'http://cyber.law.harvard.edu/rss/', '@rdf' => 'http://www.w3.org/RDF/', '@atom' => 'http://www.atomenabled.org')) . '</p>';
$output .= '<p>' . t('Current feeds are listed below, and <a href="@addfeed">new feeds may be added</a>. For each feed or feed category, the <em>latest items</em> block may be enabled at the <a href="@block">blocks administration page</a>.', array('@addfeed' => url('admin/content/aggregator/add/feed'), '@block' => url('admin/build/block'))) . '</p>';
$output .= '<p>' . t('Current feeds are listed below, and <a href="@addfeed">new feeds may be added</a>. For each feed or feed category, the <em>latest items</em> block may be enabled at the <a href="@block">blocks administration page</a>.', array('@addfeed' => url('admin/content/aggregator/add/feed'), '@block' => url('admin/structure/block'))) . '</p>';
return $output;
case 'admin/content/aggregator/add/feed':
return '<p>' . t('Add a feed in RSS, RDF or Atom format. A feed may only have one entry.') . '</p>';
......
......@@ -7,7 +7,7 @@
*/
/**
* Menu callback for admin/build/block.
* Menu callback for admin/structure/block.
*/
function block_admin_display($theme = NULL) {
global $custom_theme;
......@@ -43,7 +43,7 @@ function block_admin_display_form(&$form_state, $blocks, $theme = NULL) {
// Build the form tree.
$form = array(
'#action' => arg(4) ? url('admin/build/block/list/' . $theme_key) : url('admin/build/block'),
'#action' => arg(4) ? url('admin/structure/block/list/' . $theme_key) : url('admin/structure/block'),
'#tree' => TRUE,
);
......@@ -76,12 +76,12 @@ function block_admin_display_form(&$form_state, $blocks, $theme = NULL) {
);
$form[$key]['configure'] = array(
'#markup' => l(t('configure'),
'admin/build/block/configure/' . $block['module'] . '/' . $block['delta']),
'admin/structure/block/configure/' . $block['module'] . '/' . $block['delta']),
);
if ($block['module'] == 'block') {
$form[$key]['delete'] = array(
'#markup' => l(t('delete'),
'admin/build/block/delete/' . $block['delta']),
'admin/structure/block/delete/' . $block['delta']),
);
}
}
......@@ -119,7 +119,7 @@ function block_admin_display_form_submit($form, &$form_state) {
}
/**
* Helper function for sorting blocks on admin/build/block.
* Helper function for sorting blocks on admin/structure/block.
*
* Active blocks are sorted by region, then by weight.
* Disabled blocks are sorted by name.
......@@ -354,7 +354,7 @@ function block_admin_configure_submit($form, &$form_state) {
module_invoke($form_state['values']['module'], 'block_save', $form_state['values']['delta'], $form_state['values']);
drupal_set_message(t('The block configuration has been saved.'));
cache_clear_all();
$form_state['redirect'] = 'admin/build/block';
$form_state['redirect'] = 'admin/structure/block';
}
}
......@@ -426,7 +426,7 @@ function block_add_block_form_submit($form, &$form_state) {
drupal_set_message(t('The block has been created.'));
cache_clear_all();
$form_state['redirect'] = 'admin/build/block';
$form_state['redirect'] = 'admin/structure/block';
}
/**
......@@ -437,7 +437,7 @@ function block_box_delete(&$form_state, $bid = 0) {
$form['info'] = array('#type' => 'hidden', '#value' => $box['info'] ? $box['info'] : $box['title']);
$form['bid'] = array('#type' => 'hidden', '#value' => $bid);
return confirm_form($form, t('Are you sure you want to delete the block %name?', array('%name' => $box['info'])), 'admin/build/block', '', t('Delete'), t('Cancel'));
return confirm_form($form, t('Are you sure you want to delete the block %name?', array('%name' => $box['info'])), 'admin/structure/block', '', t('Delete'), t('Cancel'));
}
/**
......@@ -453,7 +453,7 @@ function block_box_delete_submit($form, &$form_state) {
->execute();
drupal_set_message(t('The block %name has been removed.', array('%name' => $form_state['values']['info'])));
cache_clear_all();
$form_state['redirect'] = 'admin/build/block';
$form_state['redirect'] = 'admin/structure/block';
return;
}
......
......@@ -66,7 +66,7 @@
function block_help($path, $arg) {
switch ($path) {
case 'admin/help#block':
$output = '<p>' . t('Blocks are boxes of content rendered into an area, or region, of a web page. The default theme Garland, for example, implements the regions "left sidebar", "right sidebar", "content", "header", and "footer", and a block may appear in any one of these areas. The <a href="@blocks">blocks administration page</a> provides a drag-and-drop interface for assigning a block to a region, and for controlling the order of blocks within regions.', array('@blocks' => url('admin/build/block'))) . '</p>';
$output = '<p>' . t('Blocks are boxes of content rendered into an area, or region, of a web page. The default theme Garland, for example, implements the regions "left sidebar", "right sidebar", "content", "header", and "footer", and a block may appear in any one of these areas. The <a href="@blocks">blocks administration page</a> provides a drag-and-drop interface for assigning a block to a region, and for controlling the order of blocks within regions.', array('@blocks' => url('admin/structure/block'))) . '</p>';
$output .= '<p>' . t('Although blocks are usually generated automatically by modules (like the <em>User login</em> block, for example), administrators can also define custom blocks. Custom blocks have a title, description, and body. The body of the block can be as long as necessary, and can contain content supported by any available <a href="@text-format">text format</a>.', array('@text-format' => url('admin/settings/filter'))) . '</p>';
$output .= '<p>' . t('When working with blocks, remember that:') . '</p>';
$output .= '<ul><li>' . t('since not all themes implement the same regions, or display regions in the same way, blocks are positioned on a per-theme basis.') . '</li>';
......@@ -78,12 +78,12 @@ function block_help($path, $arg) {
$output .= '<li>' . t('some dynamic blocks, such as those generated by modules, will be displayed only on certain pages.') . '</li></ul>';
$output .= '<p>' . t('For more information, see the online handbook entry for <a href="@block">Block module</a>.', array('@block' => 'http://drupal.org/handbook/modules/block/')) . '</p>';
return $output;
case 'admin/build/block':
case 'admin/structure/block':
$output = '<p>' . t('This page provides a drag-and-drop interface for assigning a block to a region, and for controlling the order of blocks within regions. To change the region or order of a block, grab a drag-and-drop handle under the <em>Block</em> column and drag the block to a new location in the list. (Grab a handle by clicking and holding the mouse while hovering over a handle icon.) Since not all themes implement the same regions, or display regions in the same way, blocks are positioned on a per-theme basis. Remember that your changes will not be saved until you click the <em>Save blocks</em> button at the bottom of the page.') . '</p>';
$output .= '<p>' . t('Click the <em>configure</em> link next to each block to configure its specific title and visibility settings. Use the <a href="@add-block">add block page</a> to create a custom block.', array('@add-block' => url('admin/build/block/add'))) . '</p>';
$output .= '<p>' . t('Click the <em>configure</em> link next to each block to configure its specific title and visibility settings. Use the <a href="@add-block">add block page</a> to create a custom block.', array('@add-block' => url('admin/structure/block/add'))) . '</p>';
return $output;
case 'admin/build/block/add':
return '<p>' . t('Use this page to create a new custom block. New blocks are disabled by default, and must be moved to a region on the <a href="@blocks">blocks administration page</a> to be visible.', array('@blocks' => url('admin/build/block'))) . '</p>';
case 'admin/structure/block/add':
return '<p>' . t('Use this page to create a new custom block. New blocks are disabled by default, and must be moved to a region on the <a href="@blocks">blocks administration page</a> to be visible.', array('@blocks' => url('admin/structure/block'))) . '</p>';
}
}
......@@ -120,38 +120,38 @@ function block_permission() {
* Implement hook_menu().
*/
function block_menu() {
$items['admin/build/block'] = array(
$items['admin/structure/block'] = array(
'title' => 'Blocks',
'description' => 'Configure what block content appears in your site\'s sidebars and other regions.',
'page callback' => 'block_admin_display',
'access arguments' => array('administer blocks'),
);
$items['admin/build/block/list'] = array(
$items['admin/structure/block/list'] = array(
'title' => 'List',
'type' => MENU_DEFAULT_LOCAL_TASK,
'weight' => -10,
);
$items['admin/build/block/list/js'] = array(
$items['admin/structure/block/list/js'] = array(
'title' => 'JavaScript List Form',
'page callback' => 'block_admin_display_js',
'access arguments' => array('administer blocks'),
'type' => MENU_CALLBACK,
);
$items['admin/build/block/configure'] = array(
$items['admin/structure/block/configure'] = array(
'title' => 'Configure block',
'page callback' => 'drupal_get_form',
'page arguments' => array('block_admin_configure'),
'access arguments' => array('administer blocks'),
'type' => MENU_CALLBACK,
);
$items['admin/build/block/delete'] = array(
$items['admin/structure/block/delete'] = array(
'title' => 'Delete block',
'page callback' => 'drupal_get_form',
'page arguments' => array('block_box_delete'),
'access arguments' => array('administer blocks'),
'type' => MENU_CALLBACK,
);
$items['admin/build/block/add'] = array(
$items['admin/structure/block/add'] = array(
'title' => 'Add block',
'page callback' => 'drupal_get_form',
'page arguments' => array('block_add_block_form'),
......@@ -160,7 +160,7 @@ function block_menu() {
);
$default = variable_get('theme_default', 'garland');
foreach (list_themes() as $key => $theme) {
$items['admin/build/block/list/' . $key] = array(
$items['admin/structure/block/list/' . $key] = array(
'title' => check_plain($theme->info['name']),
'page arguments' => array($key),
'type' => $key == $default ? MENU_DEFAULT_LOCAL_TASK : MENU_LOCAL_TASK,
......@@ -250,7 +250,7 @@ function block_page_alter($page) {
// Append region description if we are rendering the block admin page.
$item = menu_get_item();
if ($item['path'] == 'admin/build/block' && isset($visible_regions[$region])) {
if ($item['path'] == 'admin/structure/block' && isset($visible_regions[$region])) {
$description = '<div class="block-region">' . $all_regions[$region] . '</div>';
$page[$region]['block_description'] = array(
'#markup' => $description,
......@@ -384,7 +384,7 @@ function block_box_form($edit = array()) {
'#title' => t('Block description'),
'#default_value' => $edit['info'],
'#maxlength' => 64,
'#description' => t('A brief description of your block. Used on the <a href="@overview">blocks administration page</a>.', array('@overview' => url('admin/build/block'))),
'#description' => t('A brief description of your block. Used on the <a href="@overview">blocks administration page</a>.', array('@overview' => url('admin/structure/block'))),
'#required' => TRUE,
'#weight' => -19,
);
......
......@@ -37,12 +37,12 @@ class BlockTestCase extends DrupalWebTestCase {
* Test creating custom block (i.e. box), moving it to a specific region and then deleting it.
*/
function testBox() {
// Add a new box by filling out the input form on the admin/build/block/add page.
// Add a new box by filling out the input form on the admin/structure/block/add page.
$box = array();
$box['info'] = $this->randomName(8);
$box['title'] = $this->randomName(8);
$box['body'] = $this->randomName(32);
$this->drupalPost('admin/build/block/add', $box, t('Save block'));
$this->drupalPost('admin/structure/block/add', $box, t('Save block'));
// Confirm that the box has been created, and then query the created bid.
$this->assertText(t('The block has been created.'), t('Box successfully created.'));
......@@ -60,7 +60,7 @@ class BlockTestCase extends DrupalWebTestCase {
// Delete the created box & verify that it's been deleted and no longer appearing on the page.
$this->clickLink(t('delete'));
$this->drupalPost('admin/build/block/delete/' . $bid, array(), t('Delete'));
$this->drupalPost('admin/structure/block/delete/' . $bid, array(), t('Delete'));
$this->assertRaw(t('The block %title has been removed.', array('%title' => $box['info'])), t('Box successfully deleted.'));
$this->assertNoText(t($box['title']), t('Box no longer appears on page.'));
}
......@@ -69,19 +69,19 @@ class BlockTestCase extends DrupalWebTestCase {
* Test creating custom block (i.e. box) using Full HTML.
*/
function testBoxFormat() {
// Add a new box by filling out the input form on the admin/build/block/add page.
// Add a new box by filling out the input form on the admin/structure/block/add page.
$box = array();
$box['info'] = $this->randomName(8);
$box['title'] = $this->randomName(8);
$box['body'] = '<h1>Full HTML</h1>';
$box['body_format'] = 2;
$this->drupalPost('admin/build/block/add', $box, t('Save block'));
$this->drupalPost('admin/structure/block/add', $box, t('Save block'));
// Set the created box to a specific region.
$bid = db_query("SELECT bid FROM {box} WHERE info = :info", array(':info' => $box['info']))->fetchField();
$edit = array();
$edit['block_' . $bid . '[region]'] = 'left';
$this->drupalPost('admin/build/block', $edit, t('Save blocks'));
$this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
// Confirm that the box is being displayed using configured text format.
$this->assertRaw('<h1>Full HTML</h1>', t('Box successfully being displayed using Full HTML.'));
......@@ -90,9 +90,9 @@ class BlockTestCase extends DrupalWebTestCase {
// but can still submit the form without errors.
$block_admin = $this->drupalCreateUser(array('administer blocks'));
$this->drupalLogin($block_admin);
$this->drupalGet('admin/build/block/configure/block/' . $bid);
$this->drupalGet('admin/structure/block/configure/block/' . $bid);
$this->assertNoText(t('Block body'));
$this->drupalPost('admin/build/block/configure/block/' . $bid, array(), t('Save block'));
$this->drupalPost('admin/structure/block/configure/block/' . $bid, array(), t('Save block'));
$this->assertNoText(t('Please ensure that each block description is unique.'));
// Confirm that the box is still being displayed using configured text format.
......@@ -113,7 +113,7 @@ class BlockTestCase extends DrupalWebTestCase {
$edit = array();
$edit['pages'] = 'user*';
$edit['roles[2]'] = TRUE;
$this->drupalPost('admin/build/block/configure/' . $block['module'] . '/' . $block['delta'], $edit, t('Save block'));
$this->drupalPost('admin/structure/block/configure/' . $block['module'] . '/' . $block['delta'], $edit, t('Save block'));
// Move block to the left sidebar.
$this->moveBlockToRegion($block, $this->regions[1]);
......@@ -141,7 +141,7 @@ class BlockTestCase extends DrupalWebTestCase {
$block['title'] = $this->randomName(8);
// Set block title to confirm that interface works and override any custom titles.
$this->drupalPost('admin/build/block/configure/' . $block['module'] . '/' . $block['delta'], array('title' => $block['title']), t('Save block'));
$this->drupalPost('admin/structure/block/configure/' . $block['module'] . '/' . $block['delta'], array('title' => $block['title']), t('Save block'));
$this->assertText(t('The block configuration has been saved.'), t('Block title set.'));
$bid = db_query("SELECT bid FROM {block} WHERE module = :module AND delta = :delta", array(
':module' => $block['module'],
......@@ -159,7 +159,7 @@ class BlockTestCase extends DrupalWebTestCase {
// Set the block to the disabled region.
$edit = array();
$edit[$block['module'] . '_' . $block['delta'] . '[region]'] = '-1';
$this->drupalPost('admin/build/block', $edit, t('Save blocks'));
$this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
// Confirm that the block was moved to the proper region.
$this->assertText(t('The block settings have been updated.'), t('Block successfully move to disabled region.'));
......@@ -172,10 +172,10 @@ class BlockTestCase extends DrupalWebTestCase {
// For convenience of developers, put the navigation block back.
$edit = array();
$edit[$block['module'] . '_' . $block['delta'] . '[region]'] = 'left';
$this->drupalPost('admin/build/block', $edit, t('Save blocks'));
$this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
$this->assertText(t('The block settings have been updated.'), t('Block successfully move to left region.'));
$this->drupalPost('admin/build/block/configure/' . $block['module'] . '/' . $block['delta'], array('title' => 'Navigation'), t('Save block'));
$this->drupalPost('admin/structure/block/configure/' . $block['module'] . '/' . $block['delta'], array('title' => 'Navigation'), t('Save block'));
$this->assertText(t('The block configuration has been saved.'), t('Block title set.'));
}
......@@ -188,7 +188,7 @@ class BlockTestCase extends DrupalWebTestCase {
// Set the created block to a specific region.
$edit = array();
$edit[$block['module'] . '_' . $block['delta'] . '[region]'] = $region['name'];
$this->drupalPost('admin/build/block', $edit, t('Save blocks'));
$this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
// Confirm that the block was moved to the proper region.
$this->assertText(t('The block settings have been updated.'), t('Block successfully moved to %region_name region.', array( '%region_name' => $region['name'])));
......@@ -217,8 +217,8 @@ class NonDefaultBlockAdmin extends DrupalWebTestCase {
function testNonDefaultBlockAdmin() {
$admin_user = $this->drupalCreateUser(array('administer blocks', 'administer site configuration'));
$this->drupalLogin($admin_user);
$this->drupalPost('admin/build/themes', array('status[stark]' => 1), t('Save configuration'));
$this->drupalGet('admin/build/block/list/stark');
$this->drupalPost('admin/structure/themes', array('status[stark]' => 1), t('Save configuration'));
$this->drupalGet('admin/structure/block/list/stark');
$this->assertRaw('stark/layout.css', t('Stark CSS found'));
}
}
......@@ -258,7 +258,7 @@ class NewDefaultThemeBlocks extends DrupalWebTestCase {
// Turn on the Stark theme and ensure that it contains all of the blocks
// that Garland did.
$this->drupalPost('admin/build/themes', array('theme_default' => 'stark'), t('Save configuration'));
$this->drupalPost('admin/structure/themes', array('theme_default' => 'stark'), t('Save configuration'));
$result = db_query("SELECT * FROM {block} WHERE theme='stark'");
foreach ($result as $block) {
unset($block->theme, $block->bid);
......@@ -288,13 +288,13 @@ class BlockAdminThemeTestCase extends DrupalWebTestCase {
$this->drupalLogin($admin_user);
// Ensure that access to block admin page is denied when theme is disabled.
$this->drupalGet('admin/build/block/list/stark');
$this->drupalGet('admin/structure/block/list/stark');
$this->assertResponse(403, t('The block admin page for a disabled theme can not be accessed'));
// Enable admin theme and confirm that tab is accessible.
$edit['admin_theme'] = 'stark';
$this->drupalPost('admin/build/themes', $edit, t('Save configuration'));
$this->drupalGet('admin/build/block/list/stark');
$this->drupalPost('admin/structure/themes', $edit, t('Save configuration'));
$this->drupalGet('admin/structure/block/list/stark');
$this->assertResponse(200, t('The block admin page for the admin theme can be accessed'));
}
}
......@@ -63,7 +63,7 @@ function blog_help($path, $arg) {
case 'admin/help#blog':
$output = '<p>' . t('The blog module allows registered users to maintain an online journal, or <em>blog</em>. Blogs are made up of individual <em>blog entries</em>, and the blog entries are most often displayed in descending order by creation time.') . '</p>';
$output .= '<p>' . t("There is an (optional) <em>Blogs</em> menu item added to the Navigation menu, which displays all blogs available on your site, and a <em>My blog</em> item displaying the current user's blog entries. The <em>Blog entry</em> menu item under <em>Add new content</em> allows new blog entries to be created.") . '</p>';
$output .= '<p>' . t('Each blog entry is displayed with an automatic link to other blogs created by the same user. By default, blog entries have comments enabled and are automatically promoted to the site front page. The blog module also creates a <em>Recent blog posts</em> block that may be enabled at the <a href="@blocks">blocks administration page</a>.', array('@blocks' => url('admin/build/block'))) . '</p>';
$output .= '<p>' . t('Each blog entry is displayed with an automatic link to other blogs created by the same user. By default, blog entries have comments enabled and are automatically promoted to the site front page. The blog module also creates a <em>Recent blog posts</em> block that may be enabled at the <a href="@blocks">blocks administration page</a>.', array('@blocks' => url('admin/structure/block'))) . '</p>';
$output .= '<p>' . t('For more information, see the online handbook entry for <a href="@blog">Blog module</a>.', array('@blog' => 'http://drupal.org/handbook/modules/blog/')) . '</p>';
return $output;
}
......
......@@ -63,7 +63,7 @@ class BlogTestCase extends DrupalWebTestCase {
// Enable the recent blog block.
$edit = array();
$edit['blog_recent[region]'] = 'right';
$this->drupalPost('admin/build/block', $edit, t('Save blocks'));
$this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
$this->assertResponse(200);
// Do basic tests for each user.
......
......@@ -1113,7 +1113,7 @@ function book_help($path, $arg) {
switch ($path) {
case 'admin/help#book':
$output = '<p>' . t('The book module is suited for creating structured, multi-page hypertexts such as site resource guides, manuals, and Frequently Asked Questions (FAQs). It permits a document to have chapters, sections, subsections, etc. Authors with suitable permissions can add pages to a collaborative book, placing them into the existing document by adding them to a table of contents menu.') . '</p>';
$output .= '<p>' . t('Pages in the book hierarchy have navigation elements at the bottom of the page for moving through the text. These links lead to the previous and next pages in the book, and to the level above the current page in the book\'s structure. More comprehensive navigation may be provided by enabling the <em>book navigation block</em> on the <a href="@admin-block">blocks administration page</a>.', array('@admin-block' => url('admin/build/block'))) . '</p>';
$output .= '<p>' . t('Pages in the book hierarchy have navigation elements at the bottom of the page for moving through the text. These links lead to the previous and next pages in the book, and to the level above the current page in the book\'s structure. More comprehensive navigation may be provided by enabling the <em>book navigation block</em> on the <a href="@admin-block">blocks administration page</a>.', array('@admin-block' => url('admin/structure/block'))) . '</p>';
$output .= '<p>' . t('Users can select the <em>printer-friendly version</em> link visible at the bottom of a book page to generate a printer-friendly display of the page and all of its subsections. ') . '</p>';
$output .= '<p>' . t("Users with the <em>administer book outlines</em> permission can add a post of any content type to a book, by selecting the appropriate book while editing the post or by using the interface available on the post's <em>outline</em> tab.") . '</p>';
$output .= '<p>' . t('Administrators can view a list of all books on the <a href="@admin-node-book">book administration page</a>. The <em>Outline</em> page for each book allows section titles to be edited or rearranged.', array('@admin-node-book' => url('admin/content/book'))) . '</p>';
......
......@@ -214,13 +214,13 @@ class BookBlockTestCase extends DrupalWebTestCase {
function testBookNavigationBlock() {
// Set block title to confirm that the interface is availble.
$this->drupalPost('admin/build/block/configure/book/navigation', array('title' => $this->randomName(8)), t('Save block'));
$this->drupalPost('admin/structure/block/configure/book/navigation', array('title' => $this->randomName(8)), t('Save block'));
$this->assertText(t('The block configuration has been saved.'), t('Block configuration set.'));
// Set the block to a region to confirm block is availble.
$edit = array();
$edit['book_navigation[region]'] = 'footer';
$this->drupalPost('admin/build/block', $edit, t('Save blocks'));
$this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
$this->assertText(t('The block settings have been updated.'), t('Block successfully move to footer region.'));
}
}
......@@ -9,7 +9,7 @@ function color_help($path, $arg) {
case 'admin/help#color':
$output = '<p>' . t('The color module allows a site administrator to quickly and easily change the color scheme of certain themes. Although not all themes support color module, both Garland (the default theme) and Minnelli were designed to take advantage of its features. By using color module with a compatible theme, you can easily change the color of links, backgrounds, text, and other theme elements. Color module requires that your <a href="@url">file download method</a> be set to public.', array('@url' => url('admin/settings/file-system'))) . '</p>';
$output .= '<p>' . t("It is important to remember that color module saves a modified copy of the theme's specified stylesheets in the files directory. This means that if you make any manual changes to your theme's stylesheet, you must save your color settings again, even if they haven't changed. This causes the color module generated version of the stylesheets in the files directory to be recreated using the new version of the original file.") . '</p>';
$output .= '<p>' . t('To change the color settings for a compatible theme, select the "configure" link for the theme on the <a href="@themes">themes administration page</a>.', array('@themes' => url('admin/build/themes'))) . '</p>';
$output .= '<p>' . t('To change the color settings for a compatible theme, select the "configure" link for the theme on the <a href="@themes">themes administration page</a>.', array('@themes' => url('admin/structure/themes'))) . '</p>';
$output .= '<p>' . t('For more information, see the online handbook entry for <a href="@color">Color module</a>.', array('@color' => 'http://drupal.org/handbook/modules/color/')) . '</p>';
return $output;
......
......@@ -86,9 +86,9 @@
function comment_help($path, $arg) {
switch ($path) {
case 'admin/help#comment':
$output = '<p>' . t('The comment module allows visitors to comment on your posts, creating ad hoc discussion boards. Any <a href="@content-type">content type</a> may have its <em>Default comment setting</em> set to <em>Open</em> to allow comments, <em>Hidden</em> to hide existing comments and prevent new comments or <em>Closed</em> to allow existing comments to be viewed but no new comments added. Comment display settings and other controls may also be customized for each content type.', array('@content-type' => url('admin/build/types'))) . '</p>';
$output = '<p>' . t('The comment module allows visitors to comment on your posts, creating ad hoc discussion boards. Any <a href="@content-type">content type</a> may have its <em>Default comment setting</em> set to <em>Open</em> to allow comments, <em>Hidden</em> to hide existing comments and prevent new comments or <em>Closed</em> to allow existing comments to be viewed but no new comments added. Comment display settings and other controls may also be customized for each content type.', array('@content-type' => url('admin/structure/types'))) . '</p>';
$output .= '<p>' . t('Comment permissions are assigned to user roles, and are used to determine whether anonymous users (or other roles) are allowed to comment on posts. If anonymous users are allowed to comment, their individual contact information may be retained in cookies stored on their local computer for use in later comment submissions. When a comment has no replies, it may be (optionally) edited by its author. The comment module uses the same text formats and HTML tags available when creating other forms of content.') . '</p>';
$output .= '<p>' . t('Change comment settings on the content type\'s <a href="@content-type">edit page</a>.', array('@content-type' => url('admin/build/types'))) . '</p>';
$output .= '<p>' . t('Change comment settings on the content type\'s <a href="@content-type">edit page</a>.', array('@content-type' => url('admin/structure/types'))) . '</p>';
$output .= '<p>' . t('For more information, see the online handbook entry for <a href="@comment">Comment module</a>.', array('@comment' => 'http://drupal.org/handbook/modules/comment/')) . '</p>';
return $output;
......
......@@ -653,7 +653,7 @@ class CommentBlockFunctionalTest extends CommentHelperCase {
$edit = array(
'comment_recent[region]' => 'left',
);
$this->drupalPost('admin/build/block', $edit, t('Save blocks'));
$this->drupalPost('admin/structure/block', $edit, t('Save blocks'));
$this->assertText(t('The block settings have been updated.'), t('Block saved to left region.'));
// Set block title and variables.
......@@ -661,7 +661,7 @@ class CommentBlockFunctionalTest extends CommentHelperCase {
'title' => $this->randomName(),
'comment_block_count' => 2,
);
$this->drupalPost('admin/build/block/configure/comment/recent', $block, t('Save block'));
$this->drupalPost('admin/structure/block/configure/comment/recent', $block, t('Save block'));
$this->assertText(t('The block configuration has been saved.'), t('Block saved.'));
// Add some test comments, one without a subject.
......@@ -690,7 +690,7 @@ class CommentBlockFunctionalTest extends CommentHelperCase {
$block = array(
'comment_block_count' => 10,
);
$this->drupalPost('admin/build/block/configure/comment/recent', $block, t('Save block'));
$this->drupalPost('admin/structure/block/configure/comment/recent', $block, t('Save block'));
$this->assertText(t('The block configuration has been saved.'), t('Block saved.'));
// Post an additional comment.
......
......@@ -23,14 +23,14 @@ function contact_admin_categories() {
$record->category,
$record->recipients,
($record->selected ? t('Yes') : t('No')),
l(t('edit'), 'admin/build/contact/edit/' . $record->cid),
l(t('delete'), 'admin/build/contact/delete/' . $record->cid),
l(t('edit'), 'admin/structure/contact/edit/' . $record->cid),
l(t('delete'), 'admin/structure/contact/delete/' . $record->cid),
);
}
// If no categories were found, let the user know.
if (empty($rows)) {
$rows[] = array(array('data' => t('No categories available. <a href="@link">Add category</a>.', array('@link' => url('admin/build/contact/add'))), 'colspan' => 5));
$rows[] = array(array('data' => t('No categories available. <a href="@link">Add category</a>.', array('@link' => url('admin/structure/contact/add'))), 'colspan' => 5));
}
return theme('table', $header, $rows);
......@@ -122,16 +122,16 @@ function contact_admin_edit_submit($form, &$form_state) {
if (empty($form_state['values']['cid']) || $form_state['values']['contact_op'] == 'add') {
drupal_write_record('contact', $form_state['values']);
drupal_set_message(t('Category %category has been added.', array('%category' => $form_state['values']['category'])));
watchdog('mail', 'Contact form: category %category added.', array('%category' => $form_state['values']['category']), WATCHDOG_NOTICE, l(t('view'), 'admin/build/contact'));
watchdog('mail', 'Contact form: category %category added.', array('%category' => $form_state['values']['category']), WATCHDOG_NOTICE, l(t('view'), 'admin/structure/contact'));
}
else {
drupal_write_record('contact', $form_state['values'], 'cid');
drupal_set_message(t('Category %category has been updated.', array('%category' => $form_state['values']['category'])));
watchdog('mail', 'Contact form: category %category updated.', array('%category' => $form_state['values']['category']), WATCHDOG_NOTICE, l(t('view'), 'admin/build/contact'));
watchdog('mail', 'Contact form: category %category updated.', array('%category' => $form_state['values']['category']), WATCHDOG_NOTICE, l(t('view'), 'admin/structure/contact'));
}
$form_state['redirect'] = 'admin/build/contact';
$form_state['redirect'] = 'admin/structure/contact';
return;
}
......@@ -145,7 +145,7 @@ function contact_admin_delete(&$form_state, $contact) {
'#value' => $contact,
);
return confirm_form($form, t('Are you sure you want to delete %category?', array('%category' => $contact['category'])), 'admin/build/contact', t('This action cannot be undone.'), t('Delete'), t('Cancel'));
return confirm_form($form, t('Are you sure you want to delete %category?', array('%category' => $contact['category'])), 'admin/structure/contact', t('This action cannot be undone.'), t('Delete'), t('Cancel'));
}
/**
......@@ -159,7 +159,7 @@ function contact_admin_delete_submit($form, &$form_state) {
drupal_set_message(t('Category %category has been deleted.', array('%category' => $contact['category'])));
watchdog('mail', 'Contact form: category %category deleted.', array('%category' => $contact['category']), WATCHDOG_NOTICE);
$form_state['redirect'] = 'admin/build/contact';
$form_state['redirect'] = 'admin/structure/contact';
return;
}
......
......@@ -19,7 +19,7 @@ function contact_help($path, $arg) {
$output .= '<p>' . t('Customize the <a href="@contact">contact page</a> with additional information (like physical location, mailing address, and telephone number) using the <a href="@contact-settings">contact form settings page</a>. The <a href="@contact-settings">settings page</a> also provides configuration options for the maximum number of contact form submissions a user may perform per hour, and the default status of users\' personal contact forms.', array('@contact-settings' => url('admin/settings/contact'), '@contact' => url('contact'))) . '</p>';
$output .= '<p>' . t('For more information, see the online handbook entry for <a href="@contact">Contact module</a>.', array('@contact' => url('http://drupal.org/handbook/modules/contact/', array('absolute' => TRUE)))) . '</p>';
return $output;
case 'admin/build/contact':
case 'admin/structure/contact':
$output = '<p>' . t('This page lets you set up <a href="@form">your site-wide contact form</a>. To do so, add one or more categories. You can associate different recipients with each category to route e-mails to different people. For example, you can route website feedback to the webmaster and direct product information requests to the sales department. On the <a href="@settings">settings page</a>, you can customize the information shown above the contact form. This can be useful to provide additional contact information such as your postal address and telephone number.', array('@settings' => url('admin/settings/contact'), '@form' => url('contact'))) . '</p>';
if (!module_exists('menu')) {
$menu_note = t('The menu item can be customized and configured only once the menu module has been <a href="@modules-page">enabled</a>.', array('@modules-page' => url('admin/settings/modules')));
......@@ -27,7 +27,7 @@ function contact_help($path, $arg) {
else {
$menu_note = '';
}
$output .= '<p>' . t('The contact module also adds a <a href="@menu-settings">menu item</a> (disabled by default) to the navigation block.', array('@menu-settings' => url('admin/build/menu'))) . ' ' . $menu_note . '</p>';
$output .= '<p>' . t('The contact module also adds a <a href="@menu-settings">menu item</a> (disabled by default) to the navigation block.', array('@menu-settings' => url('admin/structure/menu'))) . ' ' . $menu_note . '</p>';
return $output;
}
}
......@@ -52,18 +52,18 @@ function contact_permission() {
* Implement hook_menu().
*/
function contact_menu() {
$items['admin/build/contact'] = array(
$items['admin/structure/contact'] = array(
'title' => 'Contact form',
'description' => 'Create a system contact form and set up categories for the form to use.',
'page callback' => 'contact_admin_categories',
'access arguments' => array('administer site-wide contact form'),
);
$items['admin/build/contact/list'] = array(
$items['admin/structure/contact/list'] = array(
'title' => 'List',
'page callback' => 'contact_admin_categories',
'type' => MENU_DEFAULT_LOCAL_TASK,
);
$items['admin/build/contact/add'] = array(
$items['admin/structure/contact/add'] = array(
'title' => 'Add category',
'page callback' => 'drupal_get_form',
'page arguments' => array('contact_admin_edit', 3),
......@@ -71,14 +71,14 @@ function contact_menu() {
'type' => MENU_LOCAL_TASK,
'weight' => 1,
);
$items['admin/build/contact/edit/%contact'] = array(
$items['admin/structure/contact/edit/%contact'] = array(
'title' => 'Edit contact category',
'page callback' => 'drupal_get_form',
'page arguments' => array('contact_admin_edit', 3, 4),
'access arguments' => array('administer site-wide contact form'),
'type' => MENU_CALLBACK,
);
$items['admin/build/contact/delete/%contact'] = array(
$items['admin/structure/contact/delete/%contact'] = array(
'title' => 'Delete contact',
'page callback' => 'drupal_get_form',
'page arguments' => array('contact_admin_delete', 4),
......
......@@ -16,7 +16,7 @@ function contact_site_page() {
}
elseif (!db_query("SELECT COUNT(cid) FROM {contact}")->fetchField()) {
if (user_access('administer site-wide contact form')) {
$output = t('The contact form has not been configured. <a href="@add">Add one or more categories</a> to the form.', array('@add' => url('admin/build/contact/add')));
$output = t('The contact form has not been configured. <a href="@add">Add one or more categories</a> to the form.', array('@add' => url('admin/structure/contact/add')));
}
else {
return drupal_not_found();
......
......@@ -207,7 +207,7 @@ class ContactSitewideTestCase extends DrupalWebTestCase {
$edit['recipients'] = $recipients;
$edit['reply'] = $reply;
$edit['selected'] = ($selected ? '1' : '0');
$this->drupalPost('admin/build/contact/add', $edit, t('Save'));
$this->drupalPost('admin/structure/contact/add', $edit, t('Save'));
}
/**
......@@ -225,7 +225,7 @@ class ContactSitewideTestCase extends DrupalWebTestCase {
$edit['recipients'] = $recipients;
$edit['reply'] = $reply;
$edit['selected'] = ($selected ? '1' : '0');
$this->drupalPost('admin/build/contact/edit/' . $category_id, $edit, t('Save'));
$this->drupalPost('admin/structure/contact/edit/' . $category_id, $edit, t('Save'));
return ($category_id);
}
......@@ -255,7 +255,7 @@ class ContactSitewideTestCase extends DrupalWebTestCase {
$categories = $this->getCategories();
foreach ($categories as $category) {
$category_name = db_query("SELECT category FROM {contact} WHERE cid = :cid", array(':cid' => $category))->fetchField();
$this->drupalPost('admin/build/contact/delete/' . $category, array(), t('Delete'));
$this->drupalPost('admin/structure/contact/delete/' . $category, array(), t('Delete'));
$this->assertRaw(t('Category %category has been deleted.', array('%category' => $category_name)), t('Category deleted sucessfully.'));
}
}
......
......@@ -77,8 +77,8 @@ function hook_fieldable_info() {
$return['taxonomy_term']['bundles'][$vocabulary->machine_name] = array(
'label' => $vocabulary->name,
'admin' => array(
'path' => 'admin/build/taxonomy/%taxonomy_vocabulary',
'real path' => 'admin/build/taxonomy/' . $vocabulary->vid,
'path' => 'admin/structure/taxonomy/%taxonomy_vocabulary',
'real path' => 'admin/structure/taxonomy/' . $vocabulary->vid,
'bundle argument' => 3,
'access arguments' => array('administer taxonomy'),
),
......
......@@ -94,7 +94,7 @@ function forum_form_submit($form, &$form_state) {
drupal_set_message(t('The @type %term has been updated.', array('%term' => $form_state['values']['name'], '@type' => $type)));
break;
}
$form_state['redirect'] = 'admin/build/forum';
$form_state['redirect'] = 'admin/structure/forum';
return;
}
......@@ -166,7 +166,7 @@ function forum_confirm_delete(&$form_state, $tid) {
$form['tid'] = array('#type' => 'value', '#value' => $tid);
$form['name'] = array('#type' => 'value', '#value' => $term->name);
return confirm_form($form, t('Are you sure you want to delete the forum %name?', array('%name' => $term->name)), 'admin/build/forum', t('Deleting a forum or container will also delete its sub-forums, if any. To delete posts in this forum, visit <a href="@content">content administration</a> first. This action cannot be undone.', array('@content' => url('admin/content/node'))), t('Delete'), t('Cancel'));
return confirm_form($form, t('Are you sure you want to delete the forum %name?', array('%name' => $term->name)), 'admin/structure/forum', t('Deleting a forum or container will also delete its sub-forums, if any. To delete posts in this forum, visit <a href="@content">content administration</a> first. This action cannot be undone.', array('@content' => url('admin/content/node'))), t('Delete'), t('Cancel'));
}
/**
......@@ -177,7 +177,7 @@ function forum_confirm_delete_submit($form, &$form_state) {
drupal_set_message(t('The forum %term and all sub-forums have been deleted.', array('%term' => $form_state['values']['name'])));