All Questions
86,874
questions
0
votes
0
answers
3
views
Drupal Commerce - Buy an amount of product X must add a product Y (package Europalette)
I have a shop where product (lawn/turf) can only be bought with an additional package (Europalette).
So when the user buys 1-50 items there must be automaticly added 1 Europalette as packeging into ...
-2
votes
0
answers
9
views
How to add option to get YouTube Title and YouTube channel logo YouTube Field
I am using YouTube field module and its good module but I want to add YouTube title and YouTube channel logo. Currently there are only three option available.
1. YouTube URL - available
2. YouTube ...
0
votes
0
answers
5
views
Where is the memcache parameters are set in Drupal 7?
As we already installed memcache_admin and memcache module ,we can check the status of memcache report in drupal's /admin/reports/memcache url path.
But from there how to get what's the total ...
0
votes
0
answers
6
views
Drupal webform: two visible states
I'm struggling with two visible states. WIth thE UI this is not possible.
I have an extended text/html field, which shall be visible if the following conditions match:
Scenario 1:
„System“ checked AND ...
0
votes
0
answers
27
views
"The "MenuSettings" plugin does not exist - How do I remove it from the config? [closed]
after Updating my Drupal 8 to Drupal 9 (yes I know there is 10 already out) i can not edit or add new nodes.
Uncaught PHP Exception Drupal\Component\Plugin\Exception\PluginNotFoundException: "...
0
votes
1
answer
28
views
How to display a block after renaming its id?
I have a custom block and want to change its id. But after renaming id = "main_menu_block" to "header_block", the block doesn't display.
Tried:
remove block with old id,
rename id ...
0
votes
0
answers
15
views
get view field image src url in view-fields twig file
I have a image in a view and image is showing in complete tag. basically wamt to use image as background-image style. So I want image URL rather complete image tag. I tried some code but none worked ...
0
votes
0
answers
11
views
How to disable the option time_restriction that honeypot add to the forms
In the README file for the Honeypot module, it says:
If you want to add honeypot to your own forms, or to any form through
your own
module's hook_form_alter's, you can simply place the following
...
-3
votes
0
answers
29
views
Need to test a drupal website - how can I test it manually - A beginner [closed]
I need to QA test a newly created drupal website. What is the best way to manually QA test it. I am new to Drupal
-3
votes
1
answer
23
views
Avoid adding custom CSS to a node editing form?
Situation
custom module adding styles
don't add styles to node editing form
How to avoid adding the style to the editing forms?
function crossfade_page_attachments(array &$page) {
$page['#...
0
votes
0
answers
18
views
EntityQuery to filter values returned based on List(text) field
I have a List(text) field that can have multiple values. I am trying to create an entityQuery that returns nodes with specific items are checked within the field. The variable "availableServices&...
0
votes
0
answers
41
views
Change all generated user/{uid} paths to user/{uuid} and process them without the redirect
I need to change all generated user/{uid} paths to user/{uuid} and process them without the redirect. The tricky part is that I need to:
Output canonical URLs to user/{uuid} instead of user/{uid}
...
0
votes
0
answers
42
views
Not sure how to choose between Schema API and Entity API [closed]
I would like to save and then update data fetched from an external API every X minutes.
This data will then be used to display things on the client side.
What is the best practice to store this data ? ...
-2
votes
0
answers
37
views
How do I make a computed field editable?
I have to do some calculation in webform. Below is small part of my calculation form where I have fields like
Length (Number)
Width (Number)
Thickness (Number)
Volume (Computed Field) Formula
'{% if ...
0
votes
0
answers
22
views
Trying to filter the results of the entity autocomplete form element
Currently, I am working on a module that offers the function for users that belong to specific user roles to be able to write private messages to each other.
In order for the sender to be able to add ...
1
vote
0
answers
12
views
Always charge the most expensive flat rate shipping in an order
I have a Drupal Commerce site with two product types. One has free shipping, and the other costs € 3,-. When both products are in the cart, the customer is allowed to choose either of those rates, ...
-2
votes
1
answer
53
views
Get MenuLinkContent object values
get title and link of a menu link object in. I am trying to get title and link of a MenuLinkContent object and below is my code. I want to get title and link value. How I can get the title and Link ...
-3
votes
0
answers
30
views
Novalnet: Rejected payment by card issuing bank [closed]
I'm unable to pay through Novalnet payment gateway. When I enter all my card details correctly. Novalnet doesn't process my payment and it show an error : payment rejected by card issuing bank.
I ...
0
votes
0
answers
31
views
How to add an attribute to a paragraph button link?
I'm trying to reach a variable with the html attributes of a link in a twig file, which is used for a paragraph link.
If I dump the button content, I can't dump anything past the object array.
{{ dump(...
-3
votes
0
answers
29
views
Form to Report Generation [closed]
I've only been playing with Drupal for a year. I want to take information from a submission form and have it populate a report. This is an ongoing reporting system that needs to be viewed by our ...
0
votes
0
answers
12
views
How can I ensure that the Webform module always send emails in the same language as the original submission?
I have a webform in English, translated into German.
I have webform email handlers in English, also translated into German.
Different emails are sent based on submission completion, update, and lock.
...
0
votes
1
answer
17
views
How do I display the title of the entities to which the user has no access?
I created a new content type with entity references to standard pages. I am using the Taxonomy Access Control module to control the access to these pages.
When users view a node of that content type, ...
-1
votes
0
answers
17
views
get a paricular menu url and title in programtically created block
I have a menu and added few menu in under it. Let say sub-menu
page-1 Link - https://example.com/pag-1 - meni_id: 1
page-2 Link - https://example.com/pag-2 - meni_id: 2
page-3 Link - https://example....
0
votes
1
answer
22
views
Mink unable to connect to chromedriver
I need help from someone who knows about testing web pages with Javascript in Docker containers. I have browser-based testing working and now I have scenarios which don't work without Javascript, so I'...
0
votes
0
answers
17
views
How do I programmatically provide an exposed filter value to a view?
I am validating the creation of a new node in code thus $form['#entity_builders'][] = '_my_node_builder;
In this validation code I would like to check that my_view returns no results when its exposed ...
0
votes
1
answer
43
views
Should I "composerize" my installation?
So; having been involved with a D7 / CiviCRM build a number of years ago, I started building a D10/CiviCRM build as a project to suggest to my local organisation.
I think I might have caused myself an ...
-2
votes
0
answers
30
views
Using form to create a price calculator [closed]
I want to create a module that will calculate to total price of the computer components selected by the user. It consists of some predefined checkboxes of item names and submitting it would show the ...
-1
votes
1
answer
47
views
Argument #1 ($config_factory) must be of type Drupal\Core\Config\ConfigFactoryInterface, array given
I'm writing a new module for the community and I have this error and I'm not understand what's going on.
The error:
Mensaje TypeError:
Drupal\view_mode_by_owner_role\Functors\ListOfNodeBundles::...
0
votes
1
answer
30
views
Creating a Custom Content Listing Page based on specific content type or taxonomy terms selected in the node
I am trying to create a content type that generates a list of content/nodes based on other content type or taxonomy terms selected within that node in the content type. I have a general content type ...
0
votes
1
answer
37
views
When a custom form is displayed in a custom template, ajax does not work
What I want to do
I want to display a custom form with a custom template and use ajax in it to change values in the form.
Problem
Custom template notation prevents ajax from working.
I didn't change ...
1
vote
2
answers
73
views
Why is the service “@url_helper” not found?
I am trying to add the query string with the each URL access through the browser. To accomplish it, trying to implement that through the service. But getting no solution in Drupal 9.
mymodule.services....
0
votes
0
answers
17
views
Trying to sort rows by a column in views twig template
I'm trying to sort the rows of a view in the table template but can't figure out how to sort by a particular column. I can only get it to sort by the first column. I'm trying to sort a views global ...
0
votes
0
answers
9
views
Can't Place Custom Block in BrowserTestBase
I'm trying to set up a test for my custom module. But I can't seem to place my custom block. I can place system blocks just fine. So I don't know if there's something special with a block I make in my ...
0
votes
0
answers
24
views
Use javascript code in a specific div of the webform page
I have a website that was set up using Webforms with page breaks. So on the same URL, there are multiple "pages" and div blocks on each page, with a progress bar on top so you know what &...
-3
votes
2
answers
47
views
install Drush on shared server
please i need to use drush on shared server
i allready use composer foe install drush,,
but if i use sudo command
sudo mv drush.phar /usr/local/bin/drush
, it is give me this massage
-bash: sudo: ...
0
votes
1
answer
13
views
Is it possible to have a Search API Facet to expand the results? Basically, querying this facet OR this facet?
We have a Search API View (Solr) using facets and our nodes have two separate fields for the facets. One is an address field and the facet is built on the address US States and the other field is a ...
0
votes
1
answer
25
views
Browser test reports assertion success as an error
I am running a Functional test in a class derived from BrowserTestBase. Line 105 of the test method has this assertion:
$this->assertSession()->linkExists('10000003');
The test output says:
...
0
votes
0
answers
9
views
add user input during webform custom action?
I have a simple webform with a few basic fields. It also has a private Radios - Other field for status with the following values: pending, confirmed, denied and other for administrative purposes.
...
-2
votes
0
answers
23
views
Uploading files (of any type) into a SharePoint folder
I hope you are all doing well. I would like to ask if there is any particular way that we can upload our images from a Drupal website (Image field's uploading method) into a SharePoint's folder. I ...
1
vote
1
answer
50
views
How to prepopulate the body field with the body of another node
I have a number of nodes that I use as templates, I clone them to create nodes with the same body text.
However, I want to make this process simpler by prepopulating the body field using a token that ...
-2
votes
0
answers
14
views
Drupal Composer update - Layout Builder Problem (spacing) [closed]
I recently upgraded to Drupal Version 9.5.5 using composer. When I started working on my site again I noticed that all the spacing in layout builder had been reset to zero. Other attributes are still ...
0
votes
1
answer
24
views
Patch not working
I am trying to apply patch to the core file but none solution work for me. even not able commit core file changes due composer restriction
composer.json
{
"name": "pantheon-upstreams/...
0
votes
0
answers
14
views
Trying to sort a views result by a global views conditional field
I'm attempting to use hook_views_pre_render in a Drupal 8.9.20 site to sort the results of a view by a global views conditional field and I could really use some help. I've spent some hours searching ...
-1
votes
1
answer
40
views
Exporting content from a very old site and importing into a new site
I have inherited a very old Drupal 8.3 site that is itself an upgrade from Drupal 7 almost a decade ago, and does a lot of things the old fashioned way using panels or external modules that now have ...
0
votes
1
answer
21
views
How to get web server error logging output from phpunit functional tests?
The 500 errors generated during phpunit tests aren't showing up in the Apache error logs. Where are those errors logged?
0
votes
1
answer
33
views
phpunit can't find node permissions
We have a Functional test class derived from BrowserTestBase which is passing, but the output includes a deprecation notice.
Adding non-existent permissions to a role is deprecated in drupal:9.3.0 ...
-2
votes
1
answer
35
views
Set the canonical link rel via theme's template.php for a specific views page (not a node)
I do not want to use the D7 Metatag or the MetaTag Quick modules. How can I specify a single canonical link rel for a single URL which is not a node (a view page) via the theme's template.php?
I've ...
0
votes
1
answer
49
views
Recommended way to use StringTranslationTrait in PHP8 enums
PHP8 has that new cool "enum" feature that should replace all class constants and would make coding easier and safer. One problem I encoutered is that many common Drupal traits (foremost the ...
0
votes
1
answer
6
views
Migrating URLs without titles into a link field (where the link title is optional) without them becoming NULL
I'm migrating URLs that don't have corresponding titles into a link field, and when I either don't define the title, or use the default_value plugin to set the default value to '', the value actually ...
0
votes
0
answers
20
views
Report comments / Workflow
I am trying to implement a functionality that would allow authenticated users to report comments on a forum post. My first thought was to do it using workflows but comments dont have a workflow ...