Access admin settings - Patch for Drupal > 6.2
chiddicks - June 25, 2008 - 16:42
| Project: | Login Destination |
| Version: | 6.x-2.1 |
| Component: | Code |
| Category: | bug report |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | duplicate |
Description
This is a fix for the oft-mentioned 'Access Denied' issue. The fix is very simple - the menu system now requires that all items have access control. The main menu item for login destination did not have any access control. I've also added the hook_perm, to allow non-user-1 users to be granted the ability to administer this module.
Be sure to disable this before upgrading - or, if you've upgraded while it's enabled, disable and re-enable it. The menu system caches things.
I've tested this out and everything appears to be working as before. If you're looking for a maintainer for this module, I'd be happy to do it.
| Attachment | Size |
|---|---|
| logindestination.module patch - logindestination62.patch | 937 bytes |
| full module - login_destination_d62.tar.gz | 8.83 KB |

#1
Sorry, I failed to notice the patch made by drewish. Our patches only differ in that I add a specific permission for this admining this module.
#2
work for me
#3
I have Destination URL Settings set to static URL and Redirection Settings set to a list of paths. I am not redirected on login when the condition is met.
#4
i think adding a separate permission is a good idea, marking #255093: Need to have 'access callback' to work with Drupal 6. as a duplicate.
#5
Thanks a lot guys for your work!
I have implemented your patch with minor changes and improvements.
Please download 6.x-2.0 release
Many thanks again especially for your patience.
#6
Automatically closed -- issue fixed for two weeks with no activity.
#7
Still not fixed!
$items['admin/user/login_destination'] = array('title' => 'Login destination',
'description' => 'Configure where user will go after login.',
'page callback' => 'drupal_get_form',
'page arguments' => array('login_destination_admin_settings'),
+ 'access arguments' => array('administer site configuration'),
);
for example
#8
Yes, it appears the patch committed for 6.x-2.0 didn't make it into 6.x-2.1. I've taken ARDAS's changes (based on those by chiddicks) and created this patch for 6.x-2.1.
#9
Oops - posted this patch on the duplicate issue - http://drupal.org/node/296840 - but why not just do as andypost suggested?
One less permission for admins to manage.
#10
worked for me, thanks!
#11
Duplicate of #292006: Can't see admin page