Still on Drupal 7? Security support for Drupal 7 ended on 5 January 2025. Please visit our Drupal 7 End of Life resources page to review all of your options.
I needed to return a list of users who have access to a specific permission.
For example suppose you wanted a list of users who have permission to "post comments" in the comment module. This permission is typically enabled for multiple roles.
The following function will provide such a list. It could easily be expanded to support a dynamic number of permissions, but this suits my purpose for now.
They both have links to nodes as part of the menus.
They both refer to the nodes in the following way:
l($goto->title, "/node/$goto->nid");
In an instance where both modules refer to the same node, only one of them is linking to the URLALIAS (in this case, it is "/garage/89_civic") and the other links to "/node/231."
I am working on an idea I for Organic Groups I call "autogroups," where groups are created and populated automatically based on the roles in a system.
In looking to implement my solution, I want to act on user objects after updates to a user's role. It would seem the obvious hook to implement is hook_user.
The long-awaited category module has finally been released! You can read all about the project's cool features, and its current status (and download it for CVS/4.7), at this page:
The original category module proposal explains a lot of the concepts and motivations behind this project, as well as a huge number of comments that users have left over the past few months:
this is probably bad form, but i was a bit irked since comment module adds itself to the links array, which also outputs the categories, so you get a bit less control over the display if you wanted to distinguish between the category link(s) and the "add a comment" link, for example.
a quick search and replace of "$links" to "$commentsLink" in comments.module, and then adding print $commentsLink to your theme (i use phptemplate for my engine) lets you have quite a bit more formatting power over that section of the output.
I am getting a error when using front_page on my new 4.6.4 with latest php version. The adminstration settings page just gives "Array" text and two buttons. All other modules are working fine. I was wondering if anyone has a fix?