Within an UmbracoApiController, I'm trying to use GetCropUrl on a dynamic object with an ImageCropper property.
Using GetCropUrl item.GetCropUrl("Image", "FullWidth"); returns the crop as expected.
Using an exteneded version of GetCropUrl item.GetCropUrl(propertyAlias: "Image", cropAlias: "FullWidth", useCropDimensions: true, ratioMode: ImageCropRatioMode.Height, furtherOptions: "&slimmage=true" ); returns an empty string.
public class CategoryApiController : UmbracoApiController { ... int rootId = Umbraco.TypedContentAtRoot().First().Id; var root = Umbraco.Content(rootId); var categories = rootNode.Descendants("CategoryContainer").First(); var items = categories.Descendants("CategoryItem").Where("Visible"); ... foreach (var item in Items) { if (item .HasValue("Image")){ img = TipItem.GetCropUrl( propertyAlias: "Image", cropAlias: "FullWidth", useCropDimensions: true, ratioMode: ImageCropRatioMode.Height, furtherOptions: "&slimmage=true" ); } } }
Umbraco 7 API GetCropUrl returns empty string
Within an UmbracoApiController, I'm trying to use GetCropUrl on a dynamic object with an ImageCropper property.
Using GetCropUrl item.GetCropUrl("Image", "FullWidth"); returns the crop as expected.
Using an exteneded version of GetCropUrl item.GetCropUrl(propertyAlias: "Image", cropAlias: "FullWidth", useCropDimensions: true, ratioMode: ImageCropRatioMode.Height, furtherOptions: "&slimmage=true" ); returns an empty string.
Any ideas why would be greatly appreciated.
Umbraco Version 7.2.1
You ever got this working ?
is working on a reply...