All Questions
87,478
questions
0
votes
0
answers
12
views
How to do calculations with aggregated results of a row
I'm using Views Aggregator Plus do aggregate the results of columns. However, I cannot do calculations with the result. This is because the module always does the aggregation last.
The aggregation ...
0
votes
0
answers
7
views
Drupal search_api Configuration dependes xxx configuration that will not exist after import Drupal 10 & Solr 8
I have this scenario that is basically the opposite of "it works on my machine" - mine is the only one where it doesn't work.
when running drush cim I get this error:
In ...
0
votes
0
answers
19
views
Alter Apply Coupon (Drupal Commerce)
I am developing an advanced coupon module, two-thirds of it has been completed so far; But to apply coupons for products/variation, considering that commerce does not use the Drupal hooks
how can ...
0
votes
0
answers
52
views
How to access Layout Builder blocks in nodes quickly?
Core version 10.1.6. with Olivero theme.
My problem is that accessing layout builder blocks, especially in nodes, takes me much time. For example, my homepage has several large "Hero"/"...
0
votes
0
answers
32
views
How to make #description appear on a field widget?
I have a custom field widget that extends WidgetBase. My formElement method looks like this:
public function formElement(FieldItemListInterface $items, $delta, array $element, array &$form, ...
0
votes
0
answers
21
views
Error with Quick Node Clone module - Non-reusable blocks must set an access dependency for access control
I am on Drupal version 10.1.6 and am using the Quick Node Clone module (v1.16). I can clone any nodes/pages and that all works fine. Most of my pages, if not all, are using layout builder where I can ...
-1
votes
0
answers
24
views
Ckeditor inline images won't be deleted from file system after node deleted, Drupal 10
I deleted the node, but noticed all the inline images which uploaded from ckeditor are still in the files/inline-images folder, am I missing something or these images wont be deleted at all ?
1
vote
0
answers
64
views
How to programatically and totally vanish the sidebar in the homepage?
Core version 10.1.6 with Olivero theme.
In the <front> webpage or alternatively in the Homepage content type webpage (the homepage), I wish to just totally vanish the sidebar and let main ...
1
vote
1
answer
110
views
How to programmatically trigger 403 within a drupal hook
In a module within a drupal hook I'd like to conditionally trigger a 403 for the user.
I could archieve this e. g. by throwing an exception
throw new \Symfony\Component\HttpKernel\Exception\...
1
vote
1
answer
23
views
How to convert context_definitions to PHP attribute syntax?
Drupal 10.2 enables PHP attributes to be used instead of annotations.
So I tried to create some PHP attributes for one of my blocks:
/**
* Provides an 'Ebook Navigation' Block.
*
* @Block(
* id =...
0
votes
1
answer
32
views
Twig debugging comments stuck on
I'm working on a Drupal 10 upgrade and have run into a strange problem ... the contextual edit buttons on my site will not hide. They should be hidden until you mouse over a region/block/whatever, but ...
0
votes
0
answers
14
views
Drupal wouldn't acknowledge receiving updates, so I tried running the update in GitPod terminal and now Drupal is messed up!
I setup a Drupal 10.0 test site (to do the LinkedIn Learning courses) on a windows machine using some combination of WSL, Composer, XAMPP. I would access it at https://imrodmartin-ddevgitpod-...
0
votes
0
answers
50
views
Error in Programmatically Creating Paragraphs with Layout Paragraphs
I am trying to programmatically create paragraphs using the Layout Paragraphs module. However, I'm encountering this error when saving the main entity that contains these paragraphs. I'm looking for ...
0
votes
0
answers
8
views
Received Webform email does not show the @ symbol
When we receive webform submissions emails, the email element is not allowing the @ symbol to pull through. The email are displayed with the word at instead of @. Example - steve [at] google.com. ...
-1
votes
0
answers
20
views
Fields not required for certain roles when click on ajax
I want to not required fields when i click on the certain roles
When click on the roles it checks if those roles are those that i want the fields not to be required.
It is working fine but there is ...
0
votes
1
answer
25
views
Allow certain user role to add tags
I have added a taxonomy entity reference on a node. I want users of certain roles to only select from the list and not allow them to create a new one.
A user role A to select from the list or add a ...
0
votes
0
answers
32
views
no toolbar and layout errors
Hi, I downloaded my first Drupal website using xampp following YouTube videos. I am a complete beginner, with zero coding experience. All my links do not work excluding the "get started" and ...
0
votes
0
answers
30
views
Why is my custom block name not being generated?
I created a custom block called "Heading, Body, and Link" and the name being suggested for the Twig template in the source code is block--block-content--72dacf39-0242-4eaa-9226-171add6f87d2....
0
votes
0
answers
26
views
How can I allow anonymous users to see a webform, but not submit it?
My question title sort of summarizes the issue, I'd like anonymous users to be able to see a webform on a node, but not have access to submit it without logging in. I can't find a straightforward ...
-2
votes
1
answer
29
views
Is there a module/way to send an email quarterly to a list of people about all the new content that has been published since the last email?
I need to be able to take all the users who sign up for updates on a webform and on an editable frequency email them the new content (that I choose to send them) that has been published since the last ...
0
votes
0
answers
57
views
Get the value of a custom entity field
How can I get the value of a custom field added to user profiles?
I read and tested everything I found on Google, including the following code.
$user = \Drupal\user\Entity\User::load(\Drupal::...
0
votes
0
answers
45
views
How to avoid character encoding exceptions that occur when importing CSV data in to MS SQL server?
When I try to import CSV data into my feed, I get errors like this:
Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[IMSSP]: An
error occurred translating string for input param 3 to UCS-2: No
...
0
votes
2
answers
50
views
Adding a default text [closed]
Option 1: Is there any way to write a conditional in Twig that if field1 in Drupal is empty, I can set a default text to say "Bye"
Option 2: I was also trying to use the conditional fields ...
0
votes
0
answers
73
views
How can I turn off cache on the user registration form? [closed]
In Drupal 10, the user registration form is being cached. In an incognito window, the form shows the username and password.
This is happening on an incognito page in Chrome.
This is happening using ...
0
votes
1
answer
59
views
How to add a reset button to forms?
How do I add a reset button to a form?
I have a form with a CKEditor and other fields, plus hidden fields.
How do I reset the form so all fields are empty?
0
votes
0
answers
10
views
Module search - Reminder mail from Date field in a content-type and a paragraph [closed]
I have a date field in a content type and in a paragraph. So a normal date in the future, at this time a document must be submitted.
Now I would like to provide this date with a reminder mail, for ...
-4
votes
0
answers
28
views
Drush says php modes configuration is incompatible with drush
I am trying upgrade a series of old drupal 7 sites but Drush Version : 8.3.2 installed on my shared hosting account says it has trouble with PHP modes. I've reverted the php running all the way ...
0
votes
1
answer
34
views
I can't upload images
I can't upload images with CkEditor 5 in my Drupal 10.1.6 website (which runs on PHP 8.2); all the other features work fine.
In my recent upgrade of Drupal, I switched directly from Drupal 9.4 to ...
0
votes
0
answers
15
views
Optional parameter $path declared before required parameter $langcode is implicitly treated as a required parameter in include_once()
I've just updated from PHP 7.4 to 8.1 and on the whole everything appears to be working. However I'm seeing the following over and over in our logs, to the point that it's drowning out everything else....
-2
votes
0
answers
59
views
The site does not display styles [closed]
The site does not display styles, shows only text, but mostly works.
It complains that the files do not exist.
But I checked, the files exist and there is read permission. What could be the reason
-3
votes
0
answers
21
views
Is there's a way to redirect the user to the external link to complete the 3DS
we are doing an on-site payment gateway integration. And we want to authorize the payment with 3DS authentication. So is there's any way to redirect to external link (for 3DS authentication) from ...
0
votes
0
answers
49
views
Why would Manage Display break when the content type machine name is a number?
Drupal 10.1.6
PHP 8.2.5
I am not sure how long ago it started, I just noticed it about a week ago. It only happens when the machine_name of the content type is numeric.
When I go to /admin/structure/...
-1
votes
1
answer
25
views
Migrating 2 fields into a link field
I'm looking to migrate two fields on D7 (one a link field, the other a text field) into a single link field on D10.
The meat of the migration is here:
source:
plugin: d7_paragraphs_item
bundle: ...
-3
votes
1
answer
56
views
How to unlink the site name?
Core with Olivero theme.
The site name is a link and I want to unlink it.
I want to do it because I already link to the homepage from the main menu and don't want two links to the homepage from the ...
-2
votes
0
answers
22
views
How to fix "missing schema" errors, which are reported by "Configuration inspector" module?
I have just installed the module "Configuration inspector". When I call "/admin/reports/config-inspector" I see many errors, mostly "missing schema". How can I safely fix ...
-3
votes
0
answers
34
views
How to make Drupal 9/10 friends with Sendpulse and other mailing services? [closed]
There was a task to send data from the site to the address book of the Sendpulse mailing service.
I have a type of material where there is a name and email field. It is necessary that when creating a ...
-2
votes
1
answer
27
views
Is it possible to make a theme hook suggestion for blocks according to content type?
I was hoping it was possible to do something similar to this for menus:
* Implementation of hook_theme_suggestions_HOOK_alter() for menus.
* * Make menus themeable:
* e.g. => menu--main--node-...
0
votes
0
answers
30
views
How to disable metatags for custom entity types?
I created a custom entity type, Fruits. I have the Metatag module enabled.
I did not configure any settings to put metatags on the Fruits entity type, and it does not have a Metatag field. However, ...
0
votes
0
answers
22
views
Random order IDs
Is it possible in Drupal Commerce to give random order IDs to orders?
Similar to the "Advanced Ordernumbers for VirtueMart" plugin (https://open-tools.net/documentation/ordernumber-plugin-...
-2
votes
0
answers
29
views
Auto post new node on LinkedIn company page : how? [closed]
I try to find a way to make automatic posts of my nodes to my (brand new) LinkedIn company page.
I'm using Drupal 10, and there are no supported modules to make this.
https://www.drupal.org/project/...
0
votes
0
answers
42
views
What's the standard way of passing a return URL to a form?
The scenario is simple. I've constructed a Link object whose URL points to a form. I need a way to pass a URL to that form so that proper redirection can happen after the form is submitted.
Passing a ...
0
votes
1
answer
30
views
I cannot install Geocoder
I have tried to install Geocoder v4.11 with composer require 'drupal/geocoder:^4.11' --with-all-dependencies, but instead I get incompatibility issues with Guzzle.
Problem 1
- php-http/guzzle7-...
-1
votes
1
answer
59
views
After installation, pages do not use any CSS style
I installed Drupal on Ubuntu 22.24. I'm able to get everything done, but after the installation, the next page is all messed up and I have no other permission besides looking at this page.
How can I ...
0
votes
0
answers
30
views
Drupal 10 + Apache2 behind nginx reverse proxy setup with subdirectory
I am trying to access my drupal 10 + apache2 installation through a subdirectory.
Currently I use nginx as a reverse proxy to access all my services (nextcloud, joplin, grafana) on my server. ...
-3
votes
1
answer
60
views
Is it possible to create an ecommerce website using the core alone? [closed]
I consider to create an ecommerce website using the core alone.
Products will be categorized firstly by content types and any such content type could include fields such as:
Price
Material
...
0
votes
0
answers
24
views
Custom CSS/JS combined to webform custom component gives type MIME error
I've made a custom Webform component, working well so far. A javascript library is attached to this component.
$elements['#attached']['library'][] = 'my_module/my_lib';
My client tried to add custom ...
-1
votes
2
answers
75
views
How can I compare date time values in a content form?
I want to use getString method instead of [0]['value'] how do i do that if possible and is there any other way?
-This is the array i am getting when dump their values
dump($form_state->getValue(...
0
votes
1
answer
27
views
For ECA, how can I create a flag that unpublishes a comment, using 'classic modeller'?
Rules and Rules_flag is not working well in Drupal 10.1, though I had a solution working in Drupal 9.5.
The goal: a flag on each comment that unpublishes the comment, when a user clicks the flag.
...
1
vote
0
answers
45
views
Minimum order amount
How to limit the possibility of completing an order less or more than the specified amount in Commerce 2?
For 7 there was a module: https://www.drupal.org/project/commerce_moa but not for 8+...
3
votes
1
answer
169
views
Is possible to have OR logic on block visibility?
I am on D10.
I need to place several blocks on Block Layout having different visibility conditions: for example one of them should visible BOTH in the home page and in every article of the site.
I'd ...