All Questions

Filter by
Sorted by
Tagged with
0
votes
1answer
30 views

Allowing anonymous user based on condition

I'm currently working on a custom module with an access form and set permissions for anonymous users. I'm trying to make it so that when an anonymous user enters the password in the access form, they ...
0
votes
0answers
13 views

How to use the Drupal 8 Field API to create a custom field where publisher can select from a taxonomy term and enter varchar?

I want to create a custom field type that holds the following: one of my taxonomy terms, that is a subset of a specific vocabulary a varchar 256 value I have a vocabulary defined for "identifiers." ...
0
votes
0answers
18 views

Behat and testing paragraphs

I'm using Drupal 8.7.6 and I have almost hundred Behat tests and everything works great. My problem is with more advanced tests which contains paragraphs. I started using ready contexts: https://...
0
votes
1answer
30 views

How to get the uncached version of request headers?

We need to programmatically get the request headers using the mymodule_preprocess_page hook. To do this we tried the following, however, because we have CDN, Varnish, and Drupal Cache all enabled, the ...
0
votes
0answers
14 views

Change remove from cart button to an image button

I want to change the remove-button, that removes line items from the cart to an image button representing a trash can like this: The code I am using in a custom module looks like this: <? php ...
1
vote
1answer
12 views

Configuration syncronization not importing everything

I have a remote server which I initially setup with a default Drupal 8.7.7 install. I have since been building the site on my local development server and would now like to transfer the developments ...
1
vote
0answers
41 views

Get all services that are tagged with a specific tag in *.services.yml

Is there an easy (supported) way to programatically get all services in Drupal 8 that are tagged with a specific tag? For example getting all services that are tagged with "breadcrumb_builder" tag ...
-2
votes
0answers
25 views

Generate cache before first request (issue with long load times for uncached functions/requests)

I find some questions related to mine but not exactly for Drupal 8 Performance Problem: Delay on first request Huge delay on first request due to many slow SQL queries The issue: I have some ...
-1
votes
0answers
29 views

How do I change language?

I could not change the language. I tried to change it from admin/config/regional/language/edit, but it didn't work: The language used is still English. I also cleaned the cache.
-2
votes
1answer
17 views

On #states visible GETTING ERROR jquery-1.10.2.min.js:4 Uncaught Error: Syntax error, unrecognized expression: # [on hold]

$form['select_project'] = array( '#type' => 'select', '#title' => 'Select project', '#options' => array('none' => t(' - Select - '), 'First', 'Second', 'Third'), '#required'...
0
votes
0answers
22 views

How to get only published revisions of a node?

I have several types of content that are moderated(content_moderation and workflows), in a custom validation process I need to know if a particular node has at least one published revision. Is there a ...
1
vote
0answers
14 views

Extending Core classes with the @internal tag

I need to make weights of Taxonomies translatable and only show translations of terms when you change language. To do this I need to override the OverviewTerms class from the Taxonomy module to ...
-3
votes
0answers
15 views

Drupal 8 entity browse

I want to install videos on my drupal 8 website and I created a content type and video field and I can upload video with entity browse module on drupal but when I upload video from FileZilla I cannot ...
-2
votes
0answers
8 views

Webform submission error: form ID not connected

After submitting a webform, Drupal adds to my .webform-confirmation div this line: <script>form ID not connected: 1532</script>. I also have an error in browser console: Uncaught ...
0
votes
0answers
13 views

How to remove cookies created by Getresponse iframe before user give his consent?

I have a drupal 8 website with Getresponse integration which provide a form in an iframe. This module create some cookies, which i need to hide before user give his consent. Tried with block hook, but ...
-2
votes
0answers
13 views

My github repositories list in Drupal with option deleting every repository [on hold]

Please tell me how to list the repositories of my GitHub in Drupal 8 with the ability to delete and add new repositories?
0
votes
1answer
21 views

How to alter the search api views exposed form field value?

I have a search api view. Which has an exposed some exposed filters. The exposed filters contains postal code, city and latlong field. The user will enter the city and postal code and then in the ...
0
votes
1answer
13 views

How to use Views Photos Grid module with custom minimal theme

I use Views Photos Grid module and it shows the results correctly with Stark theme. However, it shows all the images stacked in only place in my custom theme. I do include modules css and js files: &...
0
votes
0answers
33 views

How can I preprocess a node field value to make it accessible in the template level beneath field level (video template inside file field)

I am using the Video.js (HTML5 Video Player) module and I would like to add an image for the poster by loading the URL of another image field in the same node (without modifying the module itself). ...
0
votes
2answers
34 views

How to reuse existing images in field type “Image”

I have custom ContentType with one field of type Image. Currently, when I edit a node I can only upload new images from local to server. I want to have the option to select images already existing on ...
-1
votes
1answer
22 views

entity_autocomplete, multiple users

I would like a form element able to select multiple users. $form['forward_users'] = array( '#type' => 'entity_autocomplete', '#title' => t('Forward to these users (if multiple, select and ...
0
votes
1answer
27 views

How to add custom confirmation page template for a custom URL for Webform (Custom URL for confirmation page) Drupal 8

I want to show custom message on confirmation page (on custom URL). I created a custom URL in *.routing.yml file and added a method in controller class that returns an array : return [ '#theme' =&...
0
votes
1answer
19 views

How can I get lat/lon from an address?

I have these modules addressfield geofield geocoder Is there any function to which I can pass an address like Stree, zipcode city, Country and it returns a lat/lon from that address? I have ...
0
votes
1answer
18 views

Custom e-mail translation in Drupal 8

I need to send some e-mails depending on some actions. These e-mails should be translated depending on the target user's preferred language. I've seen that the mail function has a language parameter, ...
0
votes
0answers
6 views

How to remove duplicate nodes from REST export while applying fallback language

I have created a view using REST export for CT-News. It is formatted as hal_json. It is having filter(Interface translation Lang and English as checked). News is filtered based on the dates(Latest ...
-1
votes
0answers
19 views

How to write Javascript in a webform?

How to use JS for web forms, to perform logic based on the input given by the user and display the result on another field using ajax?
0
votes
0answers
10 views

How to get image URL with GraphQL?

Let's say I have a field image in a Product entity. When I query a Product, I'd like to include the URL of the field image in the response. The documentation states we can use image_url. According ...
1
vote
0answers
11 views

How to add an alias filter to the media view?

I have a path alias for my media content provided by pathauto. The media view at 'admin/content/media' shows all the content. I am able to add filter for the media entity name, type, language and ...
0
votes
2answers
36 views

How to check if a referenced entity is being used in other places?

I have a paragraph component that has a single field (reference) that calls on other paragraph components. I'd like to remove one of the paragraph reference field options so that users do not ...
0
votes
1answer
26 views

Dynamic results label for Views with Taxonomy Filters

I'm using Drupal 8 Views with Better Exposed Filters to filter a custom content type by two custom taxonomy vocabularies. Results are filtered by: Content: Published (=Yes), Content: Content type (...
0
votes
0answers
20 views

What is the difference between Content and “Content (Vary by Code)”? [on hold]

I am trying to understand what the difference between Content and Content (Vary by Code) in Views under the Show setting. I know that by setting Content, we can set the view mode for the nodes, but ...
0
votes
0answers
10 views

How to get a correct date range per country?

1 I have a Daily Expense as content type where I add the date of the expense as well as the city & country. With this information I want to output my travel history timeline/table with the period ...
0
votes
0answers
17 views

Add Class to Parent of route:<nolink> Menu Item

I am trying to work out how to add a class to the parent item of a route:<nolink> menu item. Use case: Having over a hundred Appendix pages that all reside under an Appendixes link (A view page ...
0
votes
2answers
16 views

How to change the value of a commerce token?

When an order is submitted on our D7 site an email is sent to us with all the details of the order, including the payment method. I use the token [commerce-order:payment-method] in the commerce email ...
-2
votes
0answers
18 views

Showing additional data below each bar of Horizontal stacked bar chart in drupal 8 [on hold]

I have a horizontal stacked bar chart, similar to the one mentioned here https://codepen.io/jamiecalder/pen/NrROeB I want to add additional data like 1. Percent completed Below each bar of this ...
-2
votes
0answers
12 views

source database does not contain a recognizable drupal version [on hold]

Error Message "Source database does not contain a recogonizable drupal version" has a few solutions in this site and none work in my current scenario. The Drupal table prefix fix ,Drupal database ...
0
votes
0answers
19 views

How to install the appointments module with composer?

I am trying to install the appointments module, but running composer require drupal/appointments fails because some 3rd party libraries are not installed. I am using the drupal-project composer ...
0
votes
0answers
25 views

Kernel testing a function that calls render()

I have a kernel test that is testing the render array method for a table within a controller. In this method I have added a dropbutton for an actions column. For this to display correctly in the ...
0
votes
0answers
22 views

entity_generate migration plugin with multi value fields

I haven't found any way of using entity_generate with multi value fields in Drupal 8. Does anyone have any experience in how/if we can do this? This is the relevant part of my current field mapping: ...
0
votes
1answer
11 views

Modify the error message about the maximum upload file size

I would like to modify the default error message for the maximum upload file size, but I can't find the configuration. I looked at webform general settings, individual settings, and media file ...
-1
votes
2answers
57 views

How to create a pager to display next article in particular taxonomy?

How to create a pager to display next article in particular taxonomy? I can not find any module. I tried to do this with a view. I created a view that display all content from article and add a pager,...
-4
votes
0answers
11 views

modules for login and register? [on hold]

please help with how to trigger modal without using url on any different page by clicking button that is not provided by modal
0
votes
0answers
18 views

Allow video and audio tags in views “Global: Custom text” field

We wanted to have HTML video and audio tags used within a "Global: Custom text" field. But video and audio tags get striped in output. After some debugging I found, the custom text undergoes ...
0
votes
0answers
21 views

Node update time is not picked up from JSON

I am migrating nodes through json. I am using created and changed time through json. When i am creating the nodes using 'drush migrate-import [migrate-id]' everything is perfect. Node created and ...
-2
votes
0answers
20 views

I need to customize the feed import page [on hold]

I am going to importing content types data using Feed and Feed Ex modules. I want to customize the data import page and I need to modify import page instructions so client can easily use it. I tried ...
3
votes
0answers
26 views

Can I access more information (user inputs) using delta index?

I am working on an edit form of a content type, which contains several related inline_entity_form, let's say ief1 and ief2. When I fill and submit ief1 and come to ief2, I need to access the input on ...
-3
votes
0answers
15 views

How to add colors in taxonomy? [on hold]

I want to add colors in my taxonomy terms,i don't know how to do it.I used the color field module,but still don't know how to use.
0
votes
0answers
22 views

Upload button not showing

I am using Drupal 8.4.2. I have created my content type and I have an image field in the form fields. The image upload field is showing on the page but, the upload button is not showing. If I ...
0
votes
0answers
7 views

Distance based search view to filter on near by location

I have these module installed. geocoder geofield geofield_map addressfield gmap I have a geofield field in my content type which saves the lat long from the address field. I have created a view, ...
-3
votes
0answers
26 views

How do I get a node from the URL? [on hold]

I am trying to get the node from its URL (/user/login and /user/register) in a custom module. How do I get it? I have checked other questions, such as How to get node id from URL? but I didn't find ...

15 30 50 per page