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
Hello,
I am using image cropper in umbraco 7.6.3. However the image is not displaying.
I am using the code formthe documentation :
https://our.umbraco.org/documentation/getting-started/backoffice/property-editors/built-in-property-editors/image-cropper
@{ <img src="@Url.GetCropUrl(Model.Content, "uploadBanner", "large")" /> }
But the image is not rendering.
Can someone please help.
Thanks,
kusum
Hi Kusum
What about this code:
@{ var image = Model.Content.GetPropertyValue<IPublishedContent>("uploadBanner"); } <img src="@image.GetCropUrl("large")" />
Hello Alex ,
<img src="/media/1083/banner-treasury.jpg?crop=0.034850484229366221,0.0000000000000001329726204864,0.21835342514135769,0&cropmode=percentage&width=1259&height=598&rnd=131450499270000000">
I am getting the image as the above and it is not diplaying.However when I remove evrything after the " ? " , the image is visible.
I do not understand why because on the previous umbraco instance it was the same and the image did appear.
Can you please help.
How about this
Model.Content.GetPropertyValue
Hello John,
The code is not working. I am geting an error :
Compiler Error Message: CS1061: 'object' does not contain a definition for 'First' and no extension method 'First' accepting a first argument of type 'object' could be found (are you missing a using directive or an assembly reference?)
I got it working using :
if (Model.Content.HasValue("uploadBanner"))
{
<img src="@Url.GetCropUrl(Model.Content, propertyAlias: "uploadBanner", height: 598, width: 1259)" />
}
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
Image cropper not working
Hello,
I am using image cropper in umbraco 7.6.3. However the image is not displaying.
I am using the code formthe documentation :
https://our.umbraco.org/documentation/getting-started/backoffice/property-editors/built-in-property-editors/image-cropper
But the image is not rendering.
Can someone please help.
Thanks,
kusum
Hi Kusum
What about this code:
Hello Alex ,
I am getting the image as the above and it is not diplaying.However when I remove evrything after the " ? " , the image is visible.
I do not understand why because on the previous umbraco instance it was the same and the image did appear.
Can you please help.
Thanks,
kusum
How about this
Model.Content.GetPropertyValue
Hello John,
The code is not working. I am geting an error :
Can you please help.
Thanks,
kusum
I got it working using :
{
}
is working on a reply...