Drupal 8
For those who do not know, today November 2, support for Drupal 8 has ended.For some time now, the Drupal community has been warning you to upgrade to Drupal 9, which is a painless upgrade with multiple benefits. Ver: https://www.drupal.org/psa-2021-2021-06-29 As of this November, any Drupal 8 website is potentially...
The migration system in Drupal 8 is very powerful. In very few lines of code, you can connect various data sources, process and import data into Drupal. One of those important data is URL transfer and redirects for legacy content. The good news is that redirects are entities in Drupal...
Drupal 8 dramatically improved the capabilities for creating multilingual websites. The content translation was moved to the core and an improved architecture made it much easier to internationalize complex sites. However, the language switcher could use some improvements. Here's how we customized it. As a digital agency with Catalan origins...
As ever-evolving Drupal developers, we've been in the process of moving towards a Composer-based workflow for managing our Drupal project code bases. While it is (usually) an easy leap to move from "drush dl" to "composer require" for Drupal contributed modules and themes, there is another significant opportunity for us...
Doing this for a particular order is pretty straightforward. All you need to have is the ID of the coupon code: // This is the ID of the coupon code you want to add to the order. $coupon_id = 1; /** @var \Drupal\commerce_order\Entity\OrderInterface $order */ $order = \Drupal\commerce_order\Entity\Order::load(1); $order->get('coupons')->appendItem($coupon_id); $order->save()...
The "Migrate" module in the core is one of my favourite parts of Drupal 8 and 9. It's super flexible and makes migrating content from any source you can imagine pretty easy. Today I want to show a trick I use when I receive a csv (or excel file) from...
Today I had a little problem trying to update a website in Drupal 8. This website has always had a composer in version 1, and I have already updated it several times. But I'm just starting to use docker images for local development with composer v2. Today I got the...
Drupal's "clean URLs" rewrite query strings into human-readable text. A query string is a text in a URL preceded by a "?". For example https://example.com/?q=node/44 Query strings get in the way of search engines and are bad SEO practices. Google is not bad at understanding URLs with query strings, but...
Component-based theming is becoming very popular nowadays due to several reasons. The most important ones are reusability and portability of components. Pattern Lab is a front-end framework that uses an atomic design architecture to implement the component-based design. In this article, we will discuss more about Pattern Lab and how...
This year 2021 seems to be the end of "third party cookies". For some time (even years) several browsers have been blocking them, but Chrome was not willing to do so. The reason is simple, third-party cookies are widely used for online advertising, they are an attack on the privacy...
Pagination
Have Any Project in Mind?
If you want to do something in Drupal maybe you can hire me.
Either for consulting, development or maintenance of Drupal websites.