All Questions

0
votes
0answers
29 views

How can I replace static file and media links in content with their equivalent entity references?

I imported content from another system. So, for example, the body has typical html, like this: <img src="/images/image.jpg /> All of the media assets that are referenced as static html, those ...
0
votes
0answers
11 views

how can i get list of commerce order purchased by specific user programatically?

how can i get list of commerce order purchased by specific user programatically? i want to create function for it so that other developers can use it in further development by simply calling that ...
0
votes
0answers
17 views

How can I get an image form to maintain image order after deleting one?

I have a content type with a field for images. The field accepts multiple images and after I upload several, I re-arrange them to a desired order. After re-arranging them, I can enable "Show Row ...
0
votes
0answers
22 views

Drupal 8 Webform conditionally send results to specific emails

Hello Looking for some advice on how to deal with sending conditional emails. I did some research and it can be done in Drupal 7 with Rules but since I'm new to Drupal 8 I haven't been able to figure ...
0
votes
1answer
50 views

Where can I set cardinality for a custom field?

I have a custom field defined in a module I am writing and it works correctly; but the default cardinality is unlimited and I want to limit it to 1. I am sure I need this somewhere: ->setCardinality(...
0
votes
0answers
36 views

Is there a way to set date for scheduled unpublishing?

I check in many place but I want unpublish a node after a time like unpublish after 1 day, after 1 year and send notification to the user before unpublish. I know The Sheduler module can do that but ...
0
votes
0answers
39 views

Can't place a custom block

After adding a block file to src/Plugin/Block I can't add the block on the Block Layout admin page. When I filter by block name I can see it, but then when I try to place it I can't get to the ...
0
votes
1answer
35 views

Referenced entities show old value when changing properties

I have three custom entities, all generated with Drupal Console. I only added some basicFieldDefinitions to them before testing some CRUD operations on them. I have these entities: ConfigEntity (...
0
votes
1answer
17 views

RewriteBase /folder issues on IIS for broken images

I have a Drupal 7 site hosted under a subdirectory say http://example.com/drupal. I am using IIS and SQLSRV. But all the images could not be loaded on the site as these images pointing to http://...
0
votes
0answers
21 views

Why Drupal use the cron_key?

the cron.php will run drupal_cron_run(); only if there is a valid cron_key GET parameter in the url ex: http://mydomain.fr/cron.php?cron_key=QGlhbwqm8vVuLEE7hFB80lMQxKdOPXxyfGJRr3oAseQ why not just ...
-1
votes
0answers
19 views

Add subdirectory in trusted host patterns array

How to add subdirectory in trusted_host_patterns into the settings.php page. My project is set up into multiple subdirectories e.g: http://abc.xyz.com/client/development/project-name/. Then how should ...
0
votes
1answer
29 views

Show full image path D8

I have set a Drupal 8 project into another server with some child directory. This D8 project is working good, But images are not showing due to path missing. E.g My project is setup:- http://abc.xyz....
0
votes
1answer
31 views

HttpFoundation Request POST parameters

From VueJS, I am sending a POST HTTP request to my Drupal 8 controller. Here is my Controller: <?php namespace Drupal\mymodule\Controller; use Drupal\Core\Controller\ControllerBase; use Symfony\...
0
votes
0answers
14 views

Is it possible to store a query calculation result in a search index?

I am counting nodes of a specific type associated with terms with this query: $connection = \Drupal::database(); $query = $connection->select('taxonomy_index', 'ti'); $query->join('...
0
votes
0answers
16 views

8 - Ubercart's add to cart external link not working when triggered from external domain

When trying to add a product to cart from an external domain the site gives error. The add to cart url looks like this on the external site which has a button with the link below: https://...
-2
votes
1answer
25 views

after 8.6.14 set entity reference field via form alter failed

after the core update some how the form alter set field was broken, I tried multiple methods but its not working like : $form['field_trip_reference']['widget']['#default_value'] = array(820); $...
0
votes
1answer
41 views

Add site branding to external site

Maybe I'm asking the wrong questions on google, but I can't seem to find a solution to what I'm trying to accomplish. We've created a Drupal 8 site and we need to add the existing header and footer ...
0
votes
1answer
31 views

How Can I do a content type with a 1:n field inside?

I'm a bit lost about how Drupal manage content. For example, I want to create a new content type called Game. When I create a "Game" I want to introduce "Platform" and "Release date". For example: ...
0
votes
1answer
44 views

I can see the changes I made (as an administrator) but as an anonymous user, I can't

Have you had any problems like this before? I appreciate your help. When I'm an admin and update a node (custom module), I can see the changes I made (as an administrator). However, when I'm an ...
0
votes
0answers
6 views

blt setup error import failed Acquia Search Solr Index

blt setup error import failed Acquia Search Solr Index When I run blt setup in a vagrant ssh I get the following error: In ConfigImportCommands.php line 259: The import failed due to the ...
0
votes
1answer
24 views

Display related media entities

We are using the Basic Page content type and it has an Entity Reference field (field_document) that points to the Document (Media bundle), which has a field_document_tag (taxonomy term field). The ...
1
vote
1answer
60 views

How to access raw data in twig template using views table format

I use a table format view to display a list of articles article-list using draggable views to allow editors to order the list. I customize the content of rows depending on a boolean field is_header ...
0
votes
0answers
18 views

Drupal docker deployment - where to put the core?

Are there best practices for large (multi-)site installations of drupal on docker and k8s that could help us to decide where to place the Drupal core? We have a code-base that will be used up to 100 ...
0
votes
0answers
7 views

How can I bulk manage taxonomy parent child relationships?

Using the Migrate API and the explode and entity generate plugins from Migrate Plus, I was able to bring in a couple thousand taxonomy terms. They were listed in the source as: term1/term2/term3/etc ...
1
vote
0answers
7 views

How can I use Migrate API to migrate taxonomy with an unknown level of parent child relationships in tact?

I have a JSON file with an entry that looks like this: "taxonomy": "abc/historical_controls/abc2000_2013" In my YML file I have it mapped like this: field_abc_asset_taxonomy_auto: - ...
1
vote
1answer
17 views

Should Text Format: “Full HTML” create a safe value?

When I am rendering fields I noticed that if the user selects "full html" as the WSYWIG text format on a "long text" field, a safe value is not created. For example the array would be: value (String,...
0
votes
1answer
23 views

logging into development instance of Drupal

Ive rsynced the directory structure from mywebsite.com to mywebsite.local ( on my LAN) and copied the DB . the website mywebsite.local displays the website, but i cant log with the admin user/pw ...
0
votes
0answers
38 views

The “paragraphs_type” entity type did not specify a access handler

When i try to access paragraph type page i get following error. Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException: The "paragraphs_type" entity type did not specify a access handler ...
0
votes
0answers
30 views

Preprocess Menu Link Independent of menu.html.twig?

I am hoping there is a way to alter a menu link independent of menu.html.twig Motivation is this example from Bootstrap theme menu.html.twig: {% set link_title = item.title %} {% set link_title %}{{ ...
0
votes
0answers
11 views

Maestro Webform Integration. “Field langcode is unknown.” when trying to run Orchestrator

I'm on Drupal 8 trying to add a simple workflow to a contact form. I have implemented this locally with Maestro Webform integration and it worked out alright. When implementing this on my server, the ...
-1
votes
1answer
22 views

module_invoke_all() pass arguments by reference?

when I implement the HOOK_node_presave , I can access to the $node and alter it ex: function drupal7_test_node_presave($node){ $node->title = 'Abricoooooooooooooooooo'; } the strange thing is ...
0
votes
1answer
27 views

How to download from private// following a link?

I have a custom entity (contract) created in a custom module (amap) by a bunch of BaseFieldDefinition, one of which being $fields['file1'] = BaseFieldDefinition::create('file') ->setLabel(t('...
0
votes
1answer
21 views

How to fetch nearest node based on geofield?

How to fetch nearest node based on location geofield,i want to fetch nearest node based on longitude and latitude of my current location ,for this i have installed and configured geolocation field ...
0
votes
2answers
27 views

How to reuse the same custom template in Ajax callback

I am currently trying to display a list of nodes with a custom form containing taxonomy dropdowns (placed above node list) to filter out the contents. Now, on page load all content is displaying well ...
-3
votes
1answer
24 views

Wysiwyg editor for webform 5

Is there a way to configure textarea fields in Webform 5 to use Wysiwyg editor ? preferably without coding and overlay capability (I mean something like https://www.jqueryscript.net/form/jQuery-Plugin-...
-2
votes
0answers
14 views

Understanding how drupal behaviors and drupal settings work [duplicate]

as i am pretty new to drupal and i recently got introduced to drupal behaviors, can anyone help me with passing a variable & its value in Drupal behaviors settings. Thanks in advance!
0
votes
0answers
21 views

WHERE the alias file should locate in drupal

I have tried some ways to create an alias for my local Drupal project https://www.drupal.org/node/1401522 https://www.drupal.org/project/drush/issues/831272 https://www.drupal.org/project/drush/...
0
votes
0answers
6 views

Drupal 7 Commerce KickStart 2 Installation [duplicate]

Upon installation of Drupal Commerce Kickstart, A warning prompt shows up. After finishing installation. My site looks like this. The site is a mess, images were non-existent. It's ugly compared to ...
0
votes
1answer
15 views

Configuration settings of Authcache for roles

I'm not sure about configuration of roles in Autchcache module, specifically with authenticated user role. I want to enable caching for both anonymous and authenticated users, but I want to exclude ...
0
votes
0answers
8 views

managed_files with named that already exist are being renamed, but original file name returned

I am trying to add image upload functionality to my custom module. Images are successfully being uploaded via the following: ` $form['slide']['dbs_img'] = array( '#type' => '...
0
votes
0answers
12 views

Disable authcache for webservices

Is there anyway I can disable caching for web services? After I installed and enabled authcache, I've begun to have troubles with webservices queries due to caching. If I disable authcache, all runs ...
0
votes
0answers
29 views

How to set visibility configurations and third party setting in the block programmatically?

/** * Create Custom solutions blocks for Super Category and Category Pages. */ function custom_blocks_update_8008() { $values = [ 'uuid' => '7760fb2f-5235-4390-a91b-32568da6b001', '...
0
votes
1answer
33 views

Add/List/Edit paragraphs while add/edit node

I have installed paragraph module. I have paragraph called Address contains relevant info. It is attached to node. Per page/article I have more than 100 address. If I use default Paragraph Classic ...
0
votes
1answer
12 views

D8 VBO - Pass selected values to node add form

I have a view of nodes. I'd like to be able to select rows (thinking VBO is the best) and pass those selected nodes to a form (specifically /node/add/payments) to pre-populate entity references. ...
-1
votes
0answers
38 views

Menu Link Routes via Menu UI

One of my favorite things about symfony was the routing system. Which is now in drupal. I don't have to create a hard coded link to '/contact-us.' I can just create one to the route name {{ path('...
0
votes
0answers
23 views

Missing frontpage, unable to create views and error:Notice: Undefined index entity_type

With the following symptoms, any ideas on how to repair the issue? Unable to edit frontpage (it is visible in views list) Logged error message begins with: Notice: Undefined index: entity_type in ...
0
votes
1answer
17 views

View listing page/block relationship configuration

I have a Part-Time Course content type that holds information about whatever course that needs to be added to the site. I then have a Part-Time Course Offerings content type that has two fields. ...
0
votes
1answer
50 views

Get the node ID value after submitting an attached Webform to that node

I have a Webform attached as a field to a specific content type. After the node is loaded and the Webform is submitted, I am using the below custom webform handler to get the $webform_submission ...
0
votes
0answers
39 views

Why is composer trying to install the Drupal 8.2.x-dev branch?

UPDATE: I am not going to continue to troubleshoot this. Composer is working OK in my local site, so I'm going to change my approach to deployment and stop running composer in my staging site. ...
0
votes
0answers
14 views

AJAX select field - $form_state not saved

SOLVED (see comments) I have a form with a select field (where you can select a title of a novel). This select field automatically writes a the respective ISBN of the novel into a textfield when a ...

15 30 50 per page