Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The current installation routine of Better Formats did not work for me on a new Drupal site. I needed to re-save the user permissions (without any alterations) to get it working.
However, those user permissions are not really _access permissions_, so it would be good to move them into a new "Display settings" tab on admin/settings/filters.
To keep it simple, just store them in a variable (i.e. no separate database table) as an associative array of roles => settings. Most probably we have to fork some code of user_access() into the retrieval function for those display settings.
Comments
Comment #1
dragonwize CreditAttribution: dragonwize commentedI've looked into this some more and have decided to postpone it until #378664: Break up features into smaller modules.
I tested again with new drupal install and a fresh module install and have not had seen the issue of perms not working. I've watched the DB during all steps and studied the user perms code. All is as it should be. I added cache_clear_all() after the perm insert like user_admin_perm_submit() does for good measure.
Moving the display perms would take a great deal of code duplication of the user perm system as well. So I think it best done during or after the feature split to its own module.
Comment #2
Anonymous (not verified) CreditAttribution: Anonymous commentedThe permissions have no effect on the super admin. E.g. I cannot "Hide format tips" for the super admin, or "Expand the selection fieldset by default." etc. Because the super admin role overrides everything,
Moving it into display settings would definitely be the solution. Then its just a fixed setting, not really a "permission."
Comment #3
dragonwize CreditAttribution: dragonwize commentedActually, it would act exactly the same. The super admin is a special user and as such will always be treated special by being allowed to do everything. That part of the functionality is as designed.
Comment #4
naught101 CreditAttribution: naught101 commentedSubscribing.
Dragonwise: that's just bizarre. Why would you want these options, most of which are more or less cosmetic, to be different for user1 to other admin users?
If these were moved to a better formats setting page (or just to admin/settings/filters/settings) then they could be expanded to be more than just a binary choice - for example you could have a choice like block showing: always on; on by default, user can change; off by default, user can change; always off.
Comment #5
codevoice CreditAttribution: codevoice commentedsubscribing, +1 for move to admin/settings/filters/settings
Comment #6
anrikun CreditAttribution: anrikun commentedFirst of all, thank you for this great module that is a must-use!
I completely agree with this request. These are not permissions and should be moved to settings.
Subscribing +1!
Comment #7
dragonwize CreditAttribution: dragonwize commented6.x is now unsupported.