Posted by cgonsalv on September 27, 2011 at 12:33am
9 followers
Jump to:
| Project: | Plus 1 |
| Version: | 7.x-1.x-dev |
| Component: | User interface |
| Category: | bug report |
| Priority: | critical |
| Assigned: | Unassigned |
| Status: | active |
Issue Summary
Tried installing this module on 3 different machines, same result. I enabled the module, configured the permissions but not seeing anyway to add the widget to a node. The module works on a plain install of Drupal 7. What could be preventing
the configuration interface from showing. I tried navigation directly to the URL : ....../#overlay=admin/config/user-interface/plus1 I get a 'You are not authorized to access this page.' error. I tried changing some permissions but couldn't get access to the plus1 page.
Thanks
Comments
#1
Also using on D7 and get access denied on admin/config/user-interface/plus1
Noting about Plus1 on admin/config or vertical tabs of content types.
Marking as critical, as module appears completely useless w/o ability to configure.
#2
Same as #1 - this is a show stopper in our conversion
#3
If I were to guess the problem might be somewhere in (7.x-1.x):
$items['admin/config/user-interface/plus1'] = array(
'title' => 'Plus 1',
'description' => 'Allows readers to vote on content.',
'page callback' => 'drupal_get_form',
'page arguments' => array('plus1_settings'),
'access callback' => 'plus1_user_access',
'access arguments' => array('administer the voting widget'),
'file' => 'plus1.admin.inc',
);
return $items;
}
/**
* Custom access function, works with array of permissions.
*/
function plus1_user_access() {
global $user;
$permissions = func_get_args();
if ($user->uid == 1) {
return TRUE;
}
foreach ($permissions as $perm) {
if (user_access($perm))
return TRUE;
}
}
#4
It doesn't look like there is any reason for the custom user_access function at all.
#5
Thanks, Everett, for pointing me in the right direction! As a crude test, if I force the function to return TRUE Plus1 now shows up in the Configuration menu.
I'll dig deeper and post whatever I find
#6
I'm not expiriencing this problem. Possibily because uid = 1 does not have this issue?
#8
Yes - uid 1 is checked for in the plus1_user_access function in plus1.module and returns TRUE if found.
So far, I agree with Everett - don't understand the purpose of a custom function for this and it's definitely flawed. Working on a simple solution.
#9
Same problem here - I'm not even seeing the Plus1 buttons when logged in as user1.
#10
I get the configuration page to show up, I check the content types I want to add it to and it won't show up at all in D7. I've tried this with and without Display Suite installed.
#11
It looks like the permission name changed from
administer the voting widgettoadminister the plus1 voting widget. That may explain why the callback isn't working.Looking at the other menu items, it appears that the custom callback is there to grant access in cases where the user should be able to edit something if they have any of the named permissions.
#12
It looks like the permission name changed from
administer the voting widgettoadminister the plus1 voting widget. That may explain why the callback isn't working.Looking at the other menu items, it appears that the custom callback is there to grant access in cases where the user should be able to edit something if they have any of the named permissions.