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.
Whenever I try to configure the block via the theme and whatever the theme I have this message
The website encountered an unexpected error. Please try again later. Error: Class 'Drupal\user\ContextProvider\CurrentUserContext' not found in Drupal\Component\DependencyInjection\Container->createService() (line 266 of core/lib/Drupal/Component/DependencyInjection/Container.php).
configure the theme through the admin menus works fine
I've bumped into a mis-match between how I thought I was going to do something and how Drupal seems to want me to do it. Am I missing something?
I have a view that has a rendered custom block in the footer. This block has a body (which says "your comments are invited...") and a comment section. Anonymous users are not allowed to post comments.
As it works now, the comments are disabled for Anonymous, but the body still appears: Not a great look.
I can't see a way to disable the block for anonymous users.
I am currently trying to create an option to create a block that will only appear to users with specified roles so that they can upload content to the my site. I have set the block to only appear when the users has a specified role, but it seems that every role can see the block anyways.
Just wondering if anyone has had this issue before or is it some kinda bug? Currently running 8.5.6.
First, I'd like to state that I'm a PM, not a developer (don't boo and hiss), however I can comprehend tech-speak pretty well!
I'm tracking an issue I've seen recently that may or may not have been explicitly addressed already in these forums--I've seen similar posts but none identical to what I'm experiencing.
I'm trying to get the main menu exported as json array. I can get the main menu root elements just fine, but I am stuck on getting out the sub menu items.
Below is what I got so far. How can get the submenu elements: