I agree that this approach is not ideal. But that's currently the way it's working.
I've been giving it a spin since yesterday and will probably report an issue on improving the usability or perhaps even make it default for the usual media uploader.
The only way the cropper makes sense right now is if you just replace the usual "upload" property and simply replace it with the cropper or if you use the cropper directly on a document type.
If you need to see some examples on how to render the crops I made some examples here
I've tried creating a custom image type called custom image which is a direct copy of the image media type apart from it uses an image cropper with the alias umbracoFile instead of an Upload field. This doesn't work at all however and fails to display the uploaded images in the media folder. Any ideas why?
That's what I did though and it doesn't add the images to the Media library. Could it be because I'm using the media service rather than the back office?
I see there's a lot of discussion on the new Image Cropper. I have to say it's a cool addition, however, I can't make it work.
I've been with Umbraco since the early 4 versions and as you can see I don't post much, usually I can find everything in the current posts. I've read a lot of them here but could not find the issue I'm facing.
All the sugested steps are there, Upload replaced by the Image Cropper type, crops specified, save and publish in Umbraco.
The first strange issue is that other that the original image, there isn't any other file created on the file system for the crops.Ok, fine, thoutgh maybe the new ImageProcessor does it's thing on the fly, like the old Image Resizer use to do.
However, when the path of the image is rendered using the various code methods sugested, I got something like this:
Cropper in 7.1 - how to use?
Im not sure if im doing something wrong or it is by design.
I've created the datatype:
I've added it to the image media type:
But after uploading an image to the media section i cant crop it?!
Umrabco wants me to upload another image for the crops?!?
That does'nt really make sense to me. If it's by design, could someone please explain why?
Hi Claus
I agree that this approach is not ideal. But that's currently the way it's working.
I've been giving it a spin since yesterday and will probably report an issue on improving the usability or perhaps even make it default for the usual media uploader.
The only way the cropper makes sense right now is if you just replace the usual "upload" property and simply replace it with the cropper or if you use the cropper directly on a document type.
If you need to see some examples on how to render the crops I made some examples here
/Jan
Ahhh, just changing the UmbracoFile "Upload" paramater to use the "Cropper" instead of "Upload" fixes it, and still adds files to the media library.
Perfect! (when you see the light :) )
I can see this work with a signle file. But this can't replace the multiple media picker. It seems really weird to upload the file 2 times.
Hi Dennis
Hmm, that might be a good point actually. It might be a good idea to raise a flag about this on the issue tracker
/Jan
Hi Jan,
I just created an issue: http://issues.umbraco.org/issue/U4-4529 ;
That would only be a problem if you used it directly on the Doc type, wouldnt it?
If you use it on the media type, the crop is associated with the media file.
If you then pick your images with MNTP or multi media picker, You should be sorted... Or am i wrong?
Ahh thanks to Jeroen Breuer, I see where I went wrong. You need to complety replace the upload (umbracoFile) with the image cropper.
http://issues.umbraco.org/issue/U4-4376# ;
I've tried creating a custom image type called custom image which is a direct copy of the image media type apart from it uses an image cropper with the alias umbracoFile instead of an Upload field. This doesn't work at all however and fails to display the uploaded images in the media folder. Any ideas why?
All you need to do is change the "Upload" type on your Image media type to use your "Crop" datatype, and then you're rolling.
You might interested in last weeks uHangOut where I went through the Image Cropper in detail
That's what I did though and it doesn't add the images to the Media library. Could it be because I'm using the media service rather than the back office?
I see there's a lot of discussion on the new Image Cropper. I have to say it's a cool addition, however, I can't make it work.
I've been with Umbraco since the early 4 versions and as you can see I don't post much, usually I can find everything in the current posts. I've read a lot of them here but could not find the issue I'm facing.
All the sugested steps are there, Upload replaced by the Image Cropper type, crops specified, save and publish in Umbraco.
The first strange issue is that other that the original image, there isn't any other file created on the file system for the crops.Ok, fine, thoutgh maybe the new ImageProcessor does it's thing on the fly, like the old Image Resizer use to do.
However, when the path of the image is rendered using the various code methods sugested, I got something like this:
<img src="/media/1031/dsc00357.jpg?center=0.46333333333333332,0.2425&mode=crop&width=285&height=138&rnd=130464546300000000" alt="">
Now, it's clearly one of my cropers since the with and height are the correct ones, but the image is not displayed.
Once I copy paste the image url in the browser I've got a 404 and redirect to:
/login.aspx?ReturnUrl=%2fmedia%2f1031%2fdsc00357.jpg%3fcenter%3d0.46333333333333332%2c0.2425%26amp%3bmode%3dcrop%26amp%3bwidth%3d285%26amp%3bheight%3d138%26amp%3brnd%3d130464546300000000¢er=0.46333333333333332,0.2425&mode=crop&width=285&height=138&rnd=130464546300000000
It looks like some kind of permission issue or something like that. Can anybody help?
Regards,
Zoran
is working on a reply...