Skip to content

Custom image sizes not working #28

@maxleistner

Description

@maxleistner

Settings within the theme:

Configure::write(
	'theme.image-sizes',
	[
		'rel_teaser_box'       => [
			'width'   => 600,
			'height'  => 500,
			'crop'    => true,
			'upscale' => true,
		],
		'product_image_thumbs' => [
			'width'   => 400,
			'height'  => 400,
			'crop'    => true,
			'upscale' => true,
		],
	]
);

Call within twig template:

{{ slide.product_productImages_image.sizes.product_image_thumbs | print_r }}

or

{{ slide.product_productImages_image.getThemeSized('product_image_thumbs') | print_r }}

returns:

"http://localhost:4000/uploads/2020/04/Biryani-Rezepet-Huhn-Indien-1920x1080-1-mobile-crop-400x400.jpg" (100)
in .../sloth/src/View/Extensions/SlothTwigExtension.php:99

Calling the image itself return the following error:

Class 'League\Glide\ServerFactory' not found

Bildschirmfoto 2020-08-07 um 10 08 52

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions