


pattern name for override view templates
Twig template – views-view-unformatted.html.twig contains : #} {% if title %} <h3>{{ title }}</h3> {% endif %} {% for row in rows %} {% set row_classes = [ default_row_class ? ‘views-row’, ] %} <div{{... read more
Strip HTML tags from Field Collections in Services Views
I’m trying to strip the HTML tags from a JSON response I generated using Services Views, but I’m not having any luck so far. I have a content type with a Field Collections field in it that is outputting HTML tags no matter what I do. I’ve tried the... read more
Updating node field value using custom module validation
I currently have a custom module which calls a submit custom validation function. I am trying to update a value after the validation is run. Basically, if a value is present, update a field to say “Yes”. function sitefuncs_form_alter(&$form,... read more
Change output of a field with PHP field?
I’m constructing a view in Drupal 7 with a field called “Content: Fruit”. If the value of that field is “lemon”, I want to change the output to “citrus”. How can I accomplish this? Here’s what I tried: First, I excluded... read more
How to add field to ALL webforms?
How do I add a field to all webforms? I have a website where I’m using webform for surveys and I want that on each survey there will be a field that is the same in all of the nodes/webforms. Thank you. read more
How do I display an image using the Dynamic Background module?
I have been struggling to get the Dynamic Background module working for users’ profiles. The profiles are displayed in a panel. I enabled the Panel and User sub-module and after hours of trial and error I found a CSS combination that seems to work: #page... read more
Using custom .tpl.php for fieldable panel pane view mode
I’m having a difficult time getting a view mode on an FPP to use my custom .tpl.php file. Here is hook_preprocess: function mymod_preprocess(&$variables, $hook) { $element = $variables[‘elements’]; if ($element[‘#entity_type’] ==... read more
Translate homepage meta Title and description
I have a Multilingual Drupal 7 site using i18. But how do I get my homepage meta Title and description translated? read more
How can I sort by last word in the node title field?
In one of my content type, we are storing names in the Title field. For example, title is "John Smith". Due to the recent requirement change we now need to sort results by last name. But since the name is stored in Title how can I sort by last name in the... read more
Time field not available
I’m trying to set up a CSV import to create nodes. On the Mapping page for the feed import, several of the fields in my target node type are not listed in the dropdown box to select as a target field. I don’t know why. Some info: All the fields that... read more
Proxying a subdirectory to a remote site
The goal Make all requests to a previously static page at https://www.example.com/sub/folder on server 1 (Proxy) ACTUALLY go to a Drupal site at https://other.example.com on server 2 (Origin) This is also getting setup as a multisite, because there are sub/folder2,... read more
Is it possible to override configuration with yml files?
Override configuration guide shows how users can override configuration with global $config variable, for example by using settings.php file (the same method as for D7). But is it possible to override the configuration in a similar way but with yml file? It’s... read more
Custom field widget form – Multiple values
I’ve create a custom field form widget for an entity reference field. When only one value is allowed it shows a (filtered) select list, but I want to allow user to assign multiple reference values to that field. In my use case I want it to be shown as checkboxes... read more
How to create simple confirmation page?
I want to create simple confirmation page. It means that after user change his email then he gets confirmation email with link to page. This link contains token. This link should open page for user with appropriate message (success or fail if token expired). I want to... read more
Migrate content profile:Failing with source plugin exception
I am struggling with setting up a migration from a Drupal 6 site to a Drupal 7 site. The Drupal 6 site used Content Profile nodes to store some user information that in the new site will be fields attached to the user account. I am using the Migrate module along with... read more
Licence billing
My question is regarding the recurring payment for drupal commerce. I use Commerce Licence with ‘Licence role’ and Commerce Licence Billing to make my users pay for a monthly subscription. The question I have is, how does the recurring system work? Does... read more
Upgraded Drupal 7.37 to 7.38 using Drush and its not working. update needs a higher bootstrap level to run – Error
I am new to Drupal. I am reading a book called Definitive Guide to Drupal 7. I had installed Drush on Windows 7 with Git as well. It was working last week. Since 7.38 is released I tried to update my localhost website for this particular book and I am getting an... read more
How to programatically change file user owner
I’m using drupal services module. I can upload files through web services but the problem is all created files has the same owner, that is, the user of the web services. I would like to change this user but I don’t know how to do it. I have been searching... read more