Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
In the process of migrating a v7 website to v8 I came a cross a very strange issue - This code:
<img src="@featuredPost.BlogPostThumbnail.GetCropUrl(cropAlias: "blogThumbnail", useCropDimensions: true)"/>
in a View, renders the correct ImageProcessor URL:
<img src="/media/4395/shutterstock_256320622_girl-with-tree.jpg?anchor=center&mode=crop&width=610&height=329&rnd=132276454024830000"/>
But the image as displayed, is shown as being 335 pixels in height, instead of the specified 329:
https://snipboard.io/IC3Jdm.jpg
Has anyone seen this issue?
So, I've realized that ImageProcessor just isn't getting used at all - there is no "App_Data/cache" folder.
I have compared all the configs to the 8.6.1 download, and nothing seems amiss.
Hi Heather
Can you check files and folders permissions? Mayne Umbraco can't create a folder under /app_data?
Thanks,
Alex
Okay, so using this DOES work:
featuredPost.BlogPostThumbnail.GetCropUrl(610,329)
The generated img src is:
/media/4395/shutterstock_256320622_girl-with-tree.jpg?center=0.46832782948063639,0.58439388147611493&mode=crop&width=610&height=329&rnd=132339387248830000
but this doesn't:
featuredPost.BlogPostThumbnail.GetCropUrl("blogThumbnail")
/media/4395/shutterstock_256320622_girl-with-tree.jpg?crop=0,0.093333333333333338,0,0.097650273224043641&cropmode=percentage&width=610&height=329&rnd=132339387248830000
So perhaps those parameters aren't valid for ImageProcessor...
If I edit the url in the HTML via Dev console in the browser, and remove "&width=610&height=329" - the image displays properly.
So, perhaps this is a bug in the v8 implementation of .GetCropUrl(ALIAS)...?
I've added an Issue tot he tracker for this: https://github.com/umbraco/Umbraco-CMS/issues/8116
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.
Continue discussion
GetCropUrl() using cropAlias generates incorrectly sized image
In the process of migrating a v7 website to v8 I came a cross a very strange issue - This code:
in a View, renders the correct ImageProcessor URL:
But the image as displayed, is shown as being 335 pixels in height, instead of the specified 329:
Has anyone seen this issue?
So, I've realized that ImageProcessor just isn't getting used at all - there is no "App_Data/cache" folder.
I have compared all the configs to the 8.6.1 download, and nothing seems amiss.
Hi Heather
Can you check files and folders permissions? Mayne Umbraco can't create a folder under /app_data?
Thanks,
Alex
Okay, so using this DOES work:
The generated img src is:
but this doesn't:
The generated img src is:
So perhaps those parameters aren't valid for ImageProcessor...
If I edit the url in the HTML via Dev console in the browser, and remove "&width=610&height=329" - the image displays properly.
So, perhaps this is a bug in the v8 implementation of .GetCropUrl(ALIAS)...?
I've added an Issue tot he tracker for this: https://github.com/umbraco/Umbraco-CMS/issues/8116
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.