Images are not rendered in the size defined in cropper. Umbraco 13
Hey, i pass model down to partial view and in partial view i want to render cropped image. I followed the documentation and used .GetCropUrl("alias here");
Links generated by the GetCropUrl() seems to be fine, however the dimensions are not applied for some reason. Help me please i cannot solve this.
In addition i wanted to say that I've changed the directory of storing medias.
Hi Wojciech, first of all I would like to suggest you to update your website to at least Umbraco v10 which is much more performing and powerful then v9.
In the past I had the same problem with Umbraco v11.5.0 using the "ImageCropper" datatype.
My solution has been to use, instead of image cropper, the "Media Picker" datatype configured with the crops.
You can find information about the datatype at these links:
Images are not rendered in the size defined in cropper. Umbraco 13
Hey, i pass model down to partial view and in partial view i want to render cropped image. I followed the documentation and used .GetCropUrl("alias here");
Links generated by the GetCropUrl() seems to be fine, however the dimensions are not applied for some reason. Help me please i cannot solve this.
In addition i wanted to say that I've changed the directory of storing medias.
Here are the photos:
Partial View
Website with links
Hi Wojciech, first of all I would like to suggest you to update your website to at least Umbraco v10 which is much more performing and powerful then v9.
In the past I had the same problem with Umbraco v11.5.0 using the "ImageCropper" datatype.
My solution has been to use, instead of image cropper, the "Media Picker" datatype configured with the crops.
You can find information about the datatype at these links:
Media Picker 3 for Umbraco 9
Media Picker 3 for Umbraco 10+
I hope this help you.
Adriano
I use Umbraco 13. I managed to solve the problem.
This line of code solved it for me.
In Program.cs just right above
IMPORTANT: Seems like the issue was triggered by having media source directory out of wwwroot.
By the way it didn't matter whether i used Image Media Picker or Image Cropper, the issue persisted anyway and i tried all of the variations.
You are a lifesaver!!! H5YR!!!
check that the classes you are using are not overriding the image sizes
is working on a reply...