You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running ddev composer update, ddev craft up, clearing the caches, and then refreshing the same page results in the following srcset values being output:
{# What image crop was chosen (this will map the the image transform) #}
{% setchosenImageCrop=imageEntry.imageCrop.value %}
{# Load the image into a variable #}
{% settheImage=imageEntry.singlePhoto
.eagerly()
.withTransforms([ chosenImageCrop ])
.one()
%}
{# Use the dropdown crop value to select the matching defined Image Transform to apply on the source image #}
{% do theImage.setTransform( chosenImageCrop ) %}
{# Ok, that's the base "small" transform, so lets generate larger transforms AS NEEDED #}
{% switchchosenImageCrop %}
{% case'uncropped'or'landscape32'or'landscape169'or'landscape2391'
%}
{% setsrcSet= ['420w', '720w', '1440w', '2160w'] %}
{% case'portrait23'or'square'
%}
{% setsrcSet= ['420w', '720w'] %}
{% default %}
{% setsrcSet= ['420w'] %}
{% endswitch %}
{# Now output the tag #}
<imgsrc="{{ theImage.url }}"srcset="{{ theImage.getSrcset( srcSet ) }}"width="{{ theImage.width }}"height="{{ theImage.height }}"alt="{{ imageEntry.alternativeText ??? theImage.alternativeText ??? theImage.title }}"loading="lazy"decoding="async"
/>
</div>
Here's the dump of ddev version.
ddev version
ITEM VALUE
DDEV version v1.24.2
architecture amd64
cgo_enabled 0
db ddev/ddev-dbserver-mariadb-10.11:v1.24.2
ddev-ssh-agent ddev/ddev-ssh-agent:v1.24.2
docker 27.4.1
docker-api 1.47
docker-compose v2.32.4
docker-platform orbstack
global-ddev-dir /Users/mattwilcox/.ddev
mutagen 0.18.0
os darwin
router ddev/ddev-traefik-router:v1.24.2
web ddev/ddev-webserver:v1.24.2
Craft CMS version
5.6.0.2
PHP version
8.3
Operating system and version
DDEV
Database type and version
No response
Image driver and version
No response
Installed plugins and versions
Application Info
PHP version 8.2.27
OS version Linux 6.12.9-orbstack-00297-gaa9b46293ea3
Database driver & version MySQL 8.0.40
Image driver & version Imagick 3.7.0 (ImageMagick 6.9.11-60)
Craft edition & version Craft Pro 5.6.0.2
Yii version 2.0.51
Twig version v3.15.0
Guzzle version 7.9.2
Plugins
Blitz 5.9.9
CKEditor 4.4.0
Navigation 3.0.5
SEO 5.1.10
Sprig 3.5.2
Vite 5.0.1
The text was updated successfully, but these errors were encountered:
What happened?
Description
Image Transforms are broken in Craft 5.6.0.2 on DDEV, they all output the same path.
Our project on Craft 5.5.10 outputs this code for the Image tag's
srcset
values:Running
ddev composer update
,ddev craft up
, clearing the caches, and then refreshing the same page results in the following srcset values being output:Here's the TWIG code generating the images:
Here's the dump of
ddev version
.Craft CMS version
5.6.0.2
PHP version
8.3
Operating system and version
DDEV
Database type and version
No response
Image driver and version
No response
Installed plugins and versions
Application Info
PHP version 8.2.27
OS version Linux 6.12.9-orbstack-00297-gaa9b46293ea3
Database driver & version MySQL 8.0.40
Image driver & version Imagick 3.7.0 (ImageMagick 6.9.11-60)
Craft edition & version Craft Pro 5.6.0.2
Yii version 2.0.51
Twig version v3.15.0
Guzzle version 7.9.2
Plugins
Blitz 5.9.9
CKEditor 4.4.0
Navigation 3.0.5
SEO 5.1.10
Sprig 3.5.2
Vite 5.0.1
The text was updated successfully, but these errors were encountered: