Theme developer module crashes the whole site when enabled, how to fix?

Theme developer module crashes the whole site when enabled, how to fix?

I’m working on a clean Drupal 7.x installation, downloaded Theme developer and its dependent module simplehtmldom API( another required module for Theme developer) using drush. I found out that simplehtmldom 7.x-2.x is incompatible; so I removed it, and... read more
Migrate address field

Migrate address field

I am currently searching for a example to migrate data into an address field in Drupal 8 without any luck for now. Has someone a hint for me on how to map the fields? I tried the following: my.migrate.yml file: ‘field_date_address/address_line1’:... read more
Migrate address field

Update multiple rows (with different ids and different values) using one query

I want to update multiple rows in a custom table using just one query. Each row has its own id (obviously) and different fields/values to update. Given this question and this post, i think i can achieve it with a single db_query, similar to this one: UPDATE {table}... read more
Migrate address field

Language-dependent logo

How can I use a custom logo image in Drupal 8 that is language dependent? There does not seem to be an appropriate setting in the Content and Language Translation configuration page. read more
Migrate address field

Views Data Export Permissions Problem

I have Views Data Export installed, which creates a CSV file attached to every node. This file has all of the data from a field collection field arranged as a CSV. The only user that should be able to download this CSV file is the admin (user 1) and the user that... read more
Migrate address field

Editing a Field Collection element in a custom module

In a custom module, I’d like to to edit a Field Collection element. The element is linked to a taxonomy but I think the code would look quite similar if it was to a content type. I’ve read a lot of documentation, source code, forum entries and Drupal... read more
Migrate address field

setting default language in drupal multilingual module

In my website, I have 2 language English and Marathi. 1st default language is English and I have added some content too. but now my requirement is to set default language as Marathi. I have gone to admin/config/regional/language setting and done default language as... read more
Migrate address field

Prevent dual submit on form submission

I’ve got a form that submits via AJAX and in the callback I need to rebuild certain parts of the page to reflect the newly submitted data. One of these parts is the form, which I need to clear all user input values from so it’s ready to use again.... read more
Migrate address field

How do I filter the current year?

Initially, I have installed the Token module and created a Views block containing years. I want to filter out the current year from the block (it should not show the current year). In filter criteria, I have changed content:year ([current-date:custom:Y]), but it is... read more
Migrate address field

Add file field with Form API

I’m writing a block plugin that uses the form API to allow users to edit its settings, and then output them into a template. I’m currently using <?php /** * @file * Contains Drupalmy_pluginsPluginBlockInfoWithSideImage. */ namespace... read more
Migrate address field

When I upload an image in drupal 8 the imagestyles are not shown for the first time

My settings are, allow_insecure_derivatives: true suppress_itok_output: false Editing the itok token for the image src works at the browser level. Does anyone know what causes the issue and a fix for it? Notes : When I hit CTRL+SHIFT+R in the browser the imagestyle... read more
Migrate address field

Programmatically querying via SearchApiAcquiaSearchService

I am working on a site where querying using SearchApiSolrService is successful. However, when I deploy to Acquia Cloud and attempt to access the Acquia Search using the SearchApiAcquiaSearchService I get a 403 Forbidden. Response SearchApiException: “403”... read more
Migrate address field

What is the #target_type value used by the EntityAutocomplete class?

What is the #target_type value accepted by EntityAutocomplete? The documentation for EntityAutocomplete::processEntityAutocomplete() says it’s the ID of the target entity type. How can I get a list of possible IDs I could use? read more
Migrate address field

How can we achieve multiple forms in a single page?

I have menu callback which is getting called multiple times on the same page by an AJAX request resulting rendering the form with same HTML id $items[‘mymodule/page’] = array( ‘page callback’ => ‘drupal_get_form’, ‘page... read more
Migrate address field

Captcha session reuse attack detected error message in form with anonymous user

I am experiencing a problem with the Captcha module 7.x-1.3 version (under Drupal 7.39) I don’t use webforms My form is a simple Contact form My form does not contain any AJAX field My form does not contain any file or image upload system I configured the... read more
Migrate address field

How can I programmatically render a node’s field respecting the view mode settings?

I want to render a node’s field inside a block. It works like this: <?php if ($node) { if (isset($node->field_body_secondary) && $field = $node->field_body_secondary->value) { $markup = render($field); $build = array( ‘#type’... read more
How to check in a rule if the data from a field collection has changed?

How to check in a rule if the data from a field collection has changed?

I want to add a rule (using the Rules module) for printing a message after changing a field in a field collection. The field collection consists of the following three fields: Reference to Version (type: Entity reference) Related Entities (type: Term reference)... read more
Migrate address field

Change the bulk operations confirmation page

How to change confirmation page in bulk operations? Currently it is printing “You selected the following 4 items:”. I want to list titles of all items included in the bulk operation. read more
Migrate address field

Search indexing slow query

Drupal 7.x The search module’s indexing maintenance sql query takes a couple of minutes to complete each time cron gets triggered. SELECT t.word AS realword, i.word FROM search_total t LEFT JOIN search_index i ON t.word = i.word WHERE i.word IS NULL` Database... read more
Paragraph of text in webform generated email is split into multiple lines rather than presurving single line of text

Paragraph of text in webform generated email is split into multiple lines rather than presurving single line of text

I am using a webform to send an email. The webform contains a textarea field. I have noticed that if I enter a paragraph of text in the textarea field, then that same text is split into multiple lines in the email I receive. So rather than being a single line of text... read more