All Questions

Filter by
Sorted by
Tagged with
1
vote
1answer
34 views

Update the from name in workbench email template

I'm trying to update the "from" name in my workbench email template. I created a custom module and added the following hook ('hook_mail_alter') but it's still not updating the from name for my email ...
0
votes
1answer
27 views

Navigate to page with content displays page not found error

I have a URL (/url1) that I navigate to that is showing content because of the Context module. The Context module has a condition that when the user navigates to /url1, some view blocks are rendered ...
0
votes
1answer
56 views

How to programmatically render a webform to display specific Elements

I have tried this way but not able to hide "confirmation_id" element. public function buildForm(array $form, FormStateInterface $form_state, $sid = NULL) { $my_webform_machinename = 'request_form'; $...
1
vote
0answers
30 views

How do I display an alphabetical list of Webform titles in a block? [closed]

[new] I have a series of Webforms created on my Drupal 8 site. I want to create a view that will list all of them in alphabetical order within a block. How do I create a view that will do this? [/new] ...
0
votes
0answers
18 views

Proper integration of Paragraphs in Solr Index

I have a taxonomy entity "Politician" which has a Paragraph field "Party membership", which consists of a Date Range field for the membership and an entity reference to the taxonomy entity for the ...
0
votes
1answer
26 views

Can't update radio button fields after ajax callback

I'm having troubles with a FORM in Drupal 8, the idea is: Chose a radio value from radio-estaciones to recharge radio-contaminantes, but, after the callback, the result I see is empty, but in replace ...
0
votes
0answers
31 views

Why does sql-sync fail?

I'm managing Drupal 7 and Drupal 8 sites, so I'm running Drush 8 as that's the only version that can manage both. The Drupal 8 sites are installed using Composer and my local setup runs on MAMP 5.5.1. ...
0
votes
0answers
12 views

Webform Select Widget (Listbox) Error

The "required" attribute is not working properly when the Display option "Listbox" is selected. The user is not informed that there is required field that needs to be entered when it is a List box, ...
1
vote
0answers
68 views

How do I reliably expose aggregated CSS/JS to a third party app?

(TL;DR at the bottom) For the purposes of "theming" some other internal apps based on ASP etc., I need to make a D7 site's CSS/JS available at a permanent, reliable URL; one which will also self-...
1
vote
1answer
47 views

Filter nodes by paragraph user reference

Say you have a content type Exercise which has a Related Users paragraph field. In turn, Related Users has a user reference field: (content type) exercise --> (paragraph) related_users --> (user) ...
0
votes
1answer
30 views

Difference in form when first loaded and submitted

When debugging commerce checkout panes, which are basically forms I see that form is loaded on page load(obviously). It is again loaded when I click submit and debugger goes through same lines of form,...
-4
votes
0answers
39 views

How to load menu item from cache? [closed]

I've already created menu item that list certain products. What I'm trying to do is that while loading them to the page they are loaded from cache. Is it possible to do that here? I know how to ...
-3
votes
0answers
34 views

Mismatched entity and/or field definitions after updating from drupal 8.6.10 to 8.7.10 [duplicate]

I updated my site drupal 8.610 to 8.7.10 getting below error Entity/field definitions Mismatched entity and/or field definitions The following changes were detected in the entity type and field ...
0
votes
2answers
34 views

EntityQuery for taxonomy term of specific bundle

I would like to build a query for all taxonomy terms of a specific bundle. $terms = \Drupal::entityQuery('taxonomy_term') ->condition('type','mail_template') ->execute(); This returns an ...
0
votes
1answer
20 views

Search results are not displaying on top by relevancy [closed]

I have to use "Search API" module with configured on solr server and indexed. The search results are displaying but "relevancy" content is not on top of the page. Example #1: Search key word: course ...
0
votes
0answers
35 views

Redirecting user after form submission [closed]

I know that I can build a custom submit handler and solve it through backend but my client will need to change the redirected page after a form submission. Is there a user interface way to do ...
1
vote
3answers
98 views

Getting “Call to a member function getName() on null” in custom breadcrumb

I'm trying to customize the breadcrumb of drupal 8 to get something like this: Home > category >article-title. I wrote this and I wrote the code below. namespace Drupal\module_demo\Breadcrumb; use ...
0
votes
0answers
32 views

Alter drush 9 @self alias

Forgive me as I'm new to Drupal and am getting confused about the defaults I'm seeing between different parts of the ecosystem... I'm using Drupal 8, Drush 9 and Composer to create my project and ...
0
votes
2answers
42 views

Get term value from referenced node

Drupal 8 Twig I have a content, which have entity reference field field_field_data_provider_ref, referencing another content, which itself contains a field field buisness_property_type (single ...
0
votes
2answers
21 views

How to know the Form file path [closed]

I'm new to drupal. I have a project with a form page. I want to change some things in the form. How I can find the file path it belongs to? I look for the module/custom/my_module but there is nothing ...
0
votes
2answers
85 views

How can I inject container to a class with constructor having arguments?

Fatal error: Declaration of Drupal\migrate_upgrade\MigrateUpgradeDrushRunner::create(Psr\Container\ContainerInterface $container, $options = Array) must be compatible with Drupal\Core\...
0
votes
0answers
48 views

Form errors cannot be set after form validation has finished. When trying to edit user password in webform presave hook

I'am trying to edit a user account based on the values submitted through webform, the webform is Ajax enabled and I'am using the following code to achieve this. function ...
-2
votes
1answer
27 views

I would like to create a field type “Time” [closed]

not within or as a date. If I use a number field, I'm not able to display a colon instead of comma or decimal dot. How would you solve this problem?
2
votes
1answer
65 views

How can I redirect a user after login to the current page? [duplicate]

I have a Drupal 8 site. And I have approximately 5 pages in a site. For example if a user hits login from the contact-us page the user should not redirect anywhere, they should stay on same page. How ...
0
votes
0answers
6 views

Change order and values in List (Text) field, even if there already data in database

I have a List (Text) field with list values: 0|ValueA 1|ValueB 2|ValueC 3|ValueD 3|ValueE In Field settings tab you see: There is data for this field in the database. The field settings can no ...
1
vote
1answer
30 views

How do I modify the URL to a taxonomy term?

I have a vocabulary called Industry with four terms. I have edited the terms to keep the URL to be automatically generated. They are following this convention: industry/term1, industry/term2, etc... ...
0
votes
0answers
26 views

How do I per-variation add to cart button with no selection?

I have a table that displays rows of products with there attributes, the last item on each row has the variation add to cart form. The view's self sorts on the product id to display all the ...
0
votes
0answers
39 views

How to remove the URL parameter “current” in the address of the user login page? [closed]

My user login page is displayed at mysite/user/login but when I click on the 'Log in' button in my site's menu I get redirected to mysite/user/login?current=/user/login Why is this 'current' ...
0
votes
0answers
23 views

How do I select which node fields to display while typing in an entity reference field?

I created an entity reference field to select News items to display on a page. News is a content type. How do I display not only a title, but other stylized fields of a node as I type in the entity ...
0
votes
0answers
56 views

Can't extend schema of an existing `config_object`

Use-case: Module A defines the following schema: module_a.schema.yml module_a.settings.api: type: config_object label: API settings mapping: store: type: string label: Store ...
0
votes
3answers
41 views

Ajax not working in text field

I made custom module that implements hook_form_alter that marks the field_text_field_1 textfield as Ajax-enabled. When a key is pressed inside the field_text_field_1, it should change the value in a ...
5
votes
1answer
57 views

How to save custom label as parameter for a custom entity_reference field widget?

I am creating a custom field widget for an entity_reference field. This has a custom select field and an Ajax Submit button. Once the user selects an option (entity) from the select_field and submits ...
1
vote
1answer
16 views

Drupal Leaflet View loading view block through Ajax

I created a view block for displaying geocodeed nodes on a View Leaflet map. Everything working, the map displays the markers as I want. Now, I would like to load this map throught drupal ajax I ...
0
votes
1answer
50 views

Why all core services cannot be registered in core.services.yaml?

DrupalKernel Building of Dependency Injection Container and registration of Service Providers Core provides the CoreServiceProvider, which, in addition to registering any core services that cannot ...
0
votes
1answer
36 views

How can I get single keys in multi-item config objects using debug:config?

For example, in drush I can run drush cget search_api.server.iges_solr backend_config.connector_config.port and get a useful answer. ('search_api.server.iges_solr:backend_config.connector_config....
0
votes
1answer
22 views

Copying over all the elements to a new page [closed]

I have a website where we post our events. We would love to copy the 2018 event post and then edit it, rather than copying over all the elements to a new page. Is this possible?
0
votes
1answer
19 views

Get Relationship for the Author of the Latest Comment

In a Node view, I am trying to group the latest comments by the author's field_last_name, but I am having difficulty adding this field. I tried using the the "Last comment" and "Last comment author" ...
0
votes
0answers
13 views

Path Breadcrumbs keyword argument

Trying to create a custom breadcrumb using path breadcrumbs for https://dev.tiffin.edu/search/node/% - where the % is for the site search field. I cannot figure out how to configure this as every ...
1
vote
2answers
28 views

How to change view's field (Custom-Text field specifically) value based on other field value using hook_view_pre_render?

I have created a taxonomy-term view. I have added two fields in a view: term-id and custom-text field. I want to check if term-id has children and depending upon the result, I want to set markup ...
2
votes
2answers
225 views

How can I make the coupon code field in commerce mandatory?

Using D7 commerce coupon/discount modules. I need to make the coupon field mandatory. Every order needs a coupon code entered. There is no standard "required" checkbox on the field and I tried using ...
0
votes
1answer
35 views

What is x-speed-cache-key? What is its purpose?

Our drupal site was pentested. The pentest report labeled an action involving the header X-Speed-Cache-Key as a security concern. The finding stated: Arbitrary parameters supplied to the query ...
0
votes
0answers
35 views

How do change the value of a session before form submission

I created a custom module that allows users to enter their information, and during the form submission, I set a session with the name that they type in the form: $session = \Drupal::request()->...
2
votes
0answers
44 views

Can the core link field link to path aliases with query string parameters?

I have a field that I need to support linking to internal pages. One of the main cases for this is linking to a search page with some filters already applied. In this case it is a Solr based search. ...
0
votes
0answers
11 views

How to use % arguments in Easy Breadcrumbs “Paths to replace with custom breadcrumbs”

I am trying to give a more logical breadcrumb flow to the Drupal Commerce 2 checkout path, as Commerce doesn't support breadcrumbs in the checkout process. When not displaying the current page in ...
1
vote
1answer
22 views

Programmatic access to metatag module fields

I am wondering how to programmatically access metatag module data. For example, my node has an entry for metatag description, and I see in the generated page the meta description tag, which is great. ...
-4
votes
1answer
18 views

Article “promoted to front page” also displays all images of featured slideshow [closed]

Currently using Shinbun theme and Drupal 7 (based on an existing site, as required for a project) and was struggling to create a slideshow of selected images, which I finally managed on the article ...
0
votes
1answer
17 views

Override a file from the parent theme

Adding in the child theme a CSS file with the same name as the parent theme CSS file overrides the parent file. It doesn't seem to work JavaScript files. How can I override a JavaScript file loaded ...
0
votes
1answer
15 views

Migrating input formats for taxonomies with empty description

I am trying to write custom migrations to migrate my Drupal 7 website to Drupal 8. I am currently using Drupal 8.7.10 and Drupal 7.61 for a copy of the production website. I have tried to migrate ...
0
votes
2answers
23 views

Appending Multiple Fields In Twig

I'm attempting to append two fields with some text in the middle. Using the changed date and a plain, core, text field, I can do something like this, and it works: {{ node.changed.value|date('m.d.y') ...
1
vote
0answers
27 views

Where can we translate Format settings label? [duplicate]

I am just wondering that where we can translate the Format setting labels which is configured in Manage display of content type. I checked in configuration translation, user interface translation but ...

15 30 50 per page