summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--INSTALL.txt2
-rw-r--r--modules/comment/comment.module2
-rw-r--r--modules/system/system.install14
-rw-r--r--modules/system/system.module6
-rw-r--r--modules/upload/upload.module2
-rw-r--r--modules/user/user.admin.inc2
-rw-r--r--modules/user/user.module22
7 files changed, 32 insertions, 18 deletions
diff --git a/INSTALL.txt b/INSTALL.txt
index f7ab0b6af..a2c9802e9 100644
--- a/INSTALL.txt
+++ b/INSTALL.txt
@@ -150,7 +150,7 @@ 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
-Set User Permissions Administer > User management > Access control
+Set User Permissions Administer > User management > Permissions
For more information on configuration options, read the instructions which
accompany the different configuration settings and consult the various help
diff --git a/modules/comment/comment.module b/modules/comment/comment.module
index da3951cf9..478f19da3 100644
--- a/modules/comment/comment.module
+++ b/modules/comment/comment.module
@@ -520,7 +520,7 @@ function comment_form_alter(&$form, $form_state, $form_id) {
COMMENT_ANONYMOUS_MAYNOT_CONTACT => t('Anonymous posters may not enter their contact information'),
COMMENT_ANONYMOUS_MAY_CONTACT => t('Anonymous posters may leave their contact information'),
COMMENT_ANONYMOUS_MUST_CONTACT => t('Anonymous posters must leave their contact information')),
- '#description' => t('This option is enabled when anonymous users have permission to post comments on the <a href="@url">permissions page</a>.', array('@url' => url('admin/user/access', array('fragment' => 'module-comment')))),
+ '#description' => t('This option is enabled when anonymous users have permission to post comments on the <a href="@url">permissions page</a>.', array('@url' => url('admin/user/permissions', array('fragment' => 'module-comment')))),
);
if (!user_access('post comments', user_load(array('uid' => 0)))) {
$form['comment']['comment_anonymous']['#disabled'] = TRUE;
diff --git a/modules/system/system.install b/modules/system/system.install
index 9b29eeb02..8c98a05bd 100644
--- a/modules/system/system.install
+++ b/modules/system/system.install
@@ -4440,6 +4440,20 @@ function system_update_6033() {
return $ret;
}
+/**
+ * Rename permission "administer access control" to "administer permissions".
+ */
+function system_update_6034() {
+ $ret = array();
+ $result = db_query("SELECT rid, perm FROM {permission} ORDER BY rid");
+ while ($role = db_fetch_object($result)) {
+ $renamed_permission = preg_replace('/administer access control/', 'administer permissions', $role->perm);
+ if ($renamed_permission != $role->perm) {
+ $ret[] = update_sql("UPDATE {permission} SET perm = '$renamed_permission' WHERE rid = $role->rid");
+ }
+ }
+ return $ret;
+}
/**
* @} End of "defgroup updates-5.x-to-6.x"
diff --git a/modules/system/system.module b/modules/system/system.module
index 7854b9559..87e1ba65c 100644
--- a/modules/system/system.module
+++ b/modules/system/system.module
@@ -43,7 +43,7 @@ function system_help($path, $arg) {
case 'admin/build/themes/settings':
return '<p>'. t('These options control the default display settings for your entire site, across all themes. Unless they have been overridden by a specific theme, these settings will be used.') .'</p>';
case 'admin/build/modules':
- $output = '<p>'. t('Modules are plugins for Drupal that extend its core functionality. Here you can select which modules are enabled. Once a module is enabled, new <a href="@permissions">permissions</a> might be made available. Modules can automatically be temporarily disabled to reduce server load when your site becomes extremely busy by enabling the throttle.module and checking throttle.', array('@permissions' => url('admin/user/access')));
+ $output = '<p>'. t('Modules are plugins for Drupal that extend its core functionality. Here you can select which modules are enabled. Once a module is enabled, new <a href="@permissions">permissions</a> might be made available. Modules can automatically be temporarily disabled to reduce server load when your site becomes extremely busy by enabling the throttle.module and checking throttle.', array('@permissions' => url('admin/user/permissions')));
if (module_exists('throttle')) {
$output .= ' '. t('The auto-throttle functionality must be enabled on the <a href="@throttle">throttle configuration page</a> after having enabled the throttle module.', array('@throttle' => url('admin/settings/throttle')));
}
@@ -1001,7 +1001,7 @@ function system_admin_compact_mode() {
function system_get_module_admin_tasks($module) {
static $items;
- $admin_access = user_access('administer access control');
+ $admin_access = user_access('administer permissions');
$admin_tasks = array();
if (!isset($items)) {
@@ -1020,7 +1020,7 @@ function system_get_module_admin_tasks($module) {
$admin_task_count = 0;
// Check for permissions.
if (module_hook($module, 'perm') && $admin_access) {
- $admin_tasks[-1] = l(t('Configure permissions'), 'admin/user/access', array('fragment' => 'module-'. $module));
+ $admin_tasks[-1] = l(t('Configure permissions'), 'admin/user/permissions', array('fragment' => 'module-'. $module));
}
// Check for menu items that are admin links.
diff --git a/modules/upload/upload.module b/modules/upload/upload.module
index 93de16ed2..2fe77aca6 100644
--- a/modules/upload/upload.module
+++ b/modules/upload/upload.module
@@ -18,7 +18,7 @@ function upload_help($path, $arg) {
$output .= '<p>'. t('For more information please read the configuration and customization handbook <a href="@upload">Upload page</a>.', array('@upload' => 'http://drupal.org/handbook/modules/upload/')) .'</p>';
return $output;
case 'admin/settings/upload':
- return '<p>'. t('Users with the <a href="@permissions">upload files permission</a> can upload attachments. Users with the <a href="@permissions">view uploaded files permission</a> can view uploaded attachments. You can choose which post types can take attachments on the <a href="@types">content types settings</a> page.', array('@permissions' => url('admin/user/access'), '@types' => url('admin/settings/types'))) .'</p>';
+ return '<p>'. t('Users with the <a href="@permissions">upload files permission</a> can upload attachments. Users with the <a href="@permissions">view uploaded files permission</a> can view uploaded attachments. You can choose which post types can take attachments on the <a href="@types">content types settings</a> page.', array('@permissions' => url('admin/user/permissions'), '@types' => url('admin/settings/types'))) .'</p>';
}
}
diff --git a/modules/user/user.admin.inc b/modules/user/user.admin.inc
index 6744f140f..449ff29a3 100644
--- a/modules/user/user.admin.inc
+++ b/modules/user/user.admin.inc
@@ -955,7 +955,7 @@ function theme_user_admin_account($form) {
function theme_user_admin_new_role($form) {
$header = array(t('Name'), array('data' => t('Operations'), 'colspan' => 2));
foreach (user_roles() as $rid => $name) {
- $edit_permissions = l(t('edit permissions'), 'admin/user/access/'. $rid);
+ $edit_permissions = l(t('edit permissions'), 'admin/user/permissions/'. $rid);
if (!in_array($rid, array(DRUPAL_ANONYMOUS_RID, DRUPAL_AUTHENTICATED_RID))) {
$rows[] = array($name, l(t('edit role'), 'admin/user/roles/edit/'. $rid), $edit_permissions);
}
diff --git a/modules/user/user.module b/modules/user/user.module
index fd18e2f5e..3d169127b 100644
--- a/modules/user/user.module
+++ b/modules/user/user.module
@@ -497,7 +497,7 @@ function user_fields() {
* Implementation of hook_perm().
*/
function user_perm() {
- return array('administer access control', 'administer users', 'access user profiles', 'change own username');
+ return array('administer permissions', 'administer users', 'access user profiles', 'change own username');
}
/**
@@ -923,12 +923,12 @@ function user_menu() {
);
// Admin access pages
- $items['admin/user/access'] = array(
- 'title' => 'Access control',
+ $items['admin/user/permissions'] = array(
+ 'title' => 'Permissions',
'description' => 'Determine access to features by selecting permissions for roles.',
'page callback' => 'drupal_get_form',
'page arguments' => array('user_admin_perm'),
- 'access arguments' => array('administer access control'),
+ 'access arguments' => array('administer permissions'),
'file' => 'user.admin.inc',
);
$items['admin/user/roles'] = array(
@@ -936,7 +936,7 @@ function user_menu() {
'description' => 'List, edit, or add user roles.',
'page callback' => 'drupal_get_form',
'page arguments' => array('user_admin_new_role'),
- 'access arguments' => array('administer access control'),
+ 'access arguments' => array('administer permissions'),
'file' => 'user.admin.inc',
);
$items['admin/user/roles/edit'] = array(
@@ -949,7 +949,7 @@ function user_menu() {
'title' => 'Access rules',
'description' => 'List and create rules to disallow usernames, e-mail addresses, and IP addresses.',
'page callback' => 'user_admin_access',
- 'access arguments' => array('administer access control'),
+ 'access arguments' => array('administer permissions'),
'file' => 'user.admin.inc',
);
$items['admin/user/rules/list'] = array(
@@ -1311,7 +1311,7 @@ function user_edit_form(&$form_state, $uid, $edit, $register = FALSE) {
if ($admin) {
$form['account']['status'] = array('#type' => 'radios', '#title' => t('Status'), '#default_value' => isset($edit['status']) ? $edit['status'] : 1, '#options' => array(t('Blocked'), t('Active')));
}
- if (user_access('administer access control')) {
+ if (user_access('administer permissions')) {
$roles = user_roles(1);
unset($roles[DRUPAL_AUTHENTICATED_RID]);
if ($roles) {
@@ -1540,7 +1540,7 @@ function user_user_operations($form_state = array()) {
),
);
- if (user_access('administer access control')) {
+ if (user_access('administer permissions')) {
$roles = user_roles(1);
unset($roles[DRUPAL_AUTHENTICATED_RID]); // Can't edit authenticated role.
@@ -1574,7 +1574,7 @@ function user_user_operations($form_state = array()) {
$operation = $operation_rid[0];
if ($operation == 'add_role' || $operation == 'remove_role') {
$rid = $operation_rid[1];
- if (user_access('administer access control')) {
+ if (user_access('administer permissions')) {
$operations[$form_state['values']['operation']] = array(
'callback' => 'user_multiple_role_edit',
'callback arguments' => array($operation, $rid),
@@ -1695,14 +1695,14 @@ function user_help($path, $arg) {
return '<p>'. t('This web page allows the administrators to register new users by hand. Note that you cannot have a user where either the e-mail address or the username match another user in the system.') .'</p>';
case 'admin/user/rules':
return '<p>'. t('Set up username and e-mail address access rules for new <em>and</em> existing accounts (currently logged in accounts will not be logged out). If a username or e-mail address for an account matches any deny rule, but not an allow rule, then the account will not be allowed to be created or to log in. A host rule is effective for every page view, not just registrations.') .'</p>';
- case 'admin/user/access':
+ case 'admin/user/permissions':
return '<p>'. t('Permissions let you control what users can do on your site. Each user role (defined on the <a href="@role">user roles page</a>) has its own set of permissions. For example, you could give users classified as "Administrators" permission to "administer nodes" but deny this power to ordinary, "authenticated" users. You can use permissions to reveal new features to privileged users (those with subscriptions, for example). Permissions also allow trusted users to share the administrative burden of running a busy site.', array('@role' => url('admin/user/roles'))) .'</p>';
case 'admin/user/roles':
return t('<p>Roles allow you to fine tune the security and administration of Drupal. A role defines a group of users that have certain privileges as defined in <a href="@permissions">user permissions</a>. Examples of roles include: anonymous user, authenticated user, moderator, administrator and so on. In this area you will define the <em>role names</em> of the various roles. To delete a role choose "edit".</p><p>By default, Drupal comes with two user roles:</p>
<ul>
<li>Anonymous user: this role is used for users that don\'t have a user account or that are not authenticated.</li>
<li>Authenticated user: this role is automatically granted to all logged in users.</li>
- </ul>', array('@permissions' => url('admin/user/access')));
+ </ul>', array('@permissions' => url('admin/user/permissions')));
case 'admin/user/search':
return '<p>'. t('Enter a simple pattern ("*" may be used as a wildcard match) to search for a username or e-mail address. For example, one may search for "br" and Drupal might return "brian", "brad", and "brenda@example.com".') .'</p>';
}