Hi everyone,
is there any way to change a picture uploaded by image cropper to a standard media Image?
I cannot work out quite how to do it.
I need to do this in a model or a controller, so C# please.
Basically I need to 'copy' the base image without the cropping into the media picker field on a different ipublishedcontent object.
Change Crop Image to standard media
Hi everyone, is there any way to change a picture uploaded by image cropper to a standard media Image?
I cannot work out quite how to do it.
I need to do this in a model or a controller, so C# please. Basically I need to 'copy' the base image without the cropping into the media picker field on a different ipublishedcontent object.
Cheers for any help.
Ok, given I didn't have any replies or suggestions I am posting a workaround.
This is messy and should only be used if there is no other option.
Get the cropped image, then create a new media item using the image source.
im is my image folder node.
tp[] is an array of strings (file path split by '/') index 3 is the name of the file.
is working on a reply...