Skip to main content

Posts

Featured

Drupal: Migrate image styles from D7 to D8

Recently, I needed to do such a thing. Unfortunately, there is no easy upgrade process. You have to recreate the image styles one by one. In my case each and every image style used a custom image effect for resizing images; so I needed to upgrade the image effect module too.

After enabling my image effect module, I created an image style from the UI exactly as it was in D7.

Then I used Configuration Management module to export the image.xxxxxx.yml file containing the configuration. In my case it was something like the following:

langcode: en status: true dependencies: module: - my_custom_image_effects name: teaser_thumbnail_620dp_xhdpi label: teaser-thumbnail for 620dp-xhdpi (scale) effects: 0f65ef39-260c-453e-b157-6e031d11adc0: uuid: 0f65ef39-260c-453e-b157-6e031d11adc0 id: minimum_resize weight: 1 data: width: '1240' height: '' upscale: false pipeline: '' Step #1 I created a new module in D7, using the Features…

Latest Posts

PHP: Memory consumption in different scenarios by counting memory used by PHP (but not allocated to PHP)

hook_field_extra_fields() are enabled by default on all content types

Drupal Migrate: Update entities without overwriting values

Change language to send an email

How to use rsync to sync remote and local filesystems or servers

Export your simplenews subscriptions to Mailchimp

Override the default Opigno LMS navigation menu

Two small linux tips and tricks

Help, I' m leaking PHP memory!

Fixing the Drupal Dashboard (empty) bug