If you are using Umbraco v4.5 the datatype is already installed but you need to create it in the developer section. Just right click "datatypes" and pick "create". Give your cropper af name and select the image cropper datatype from the dropdown list.
Hmm...then I'm wondering if you could benefit from using the upload datatype. There you can actually specify thumbnail sizes. You can specify more than one.
What you need to do is to go to the developer section and select the upload datatype and then write the values you need in there. This i probably documented somewhere else also, but for now I can just remember you can see how to do it by having a look at Doug's slides from the uk festival: http://umbracoukfestival.co.uk/media/676/did%20you%20know%20-%20umbraco%20uk%20festival.pdf page 22.
Use the ImageGen package to resize the images. It works better than the imagecropper as long as you want your image to be resized, and not cropped (unless you buy the pro version of ImageGen)
Here is a demo using imagecropper, though i should mention that we stopped using it because it has a lot of data-entry issues for content managers (crops don't get created untill you save the image at least twice, and all crops must be defined manually otherwise it takes the smallest possible area of the image, instead of the largest. Since this feature is caused by the way Umbraco works, it won't be fixed before Umbraco 5.0)
Ahh... Upload datatype resizes image, and i need to crop it and use first couple pixels.
Im building a page header with image in middle, and i need to expand image edge color to the page edges. My initial idea is to repeat cropped image to the edges of page. I could do this also with a backround color if i could take it from first image pixel.
@Rik:
I need to crop image, so free ImageGen version could not help me.
You're probably right, i looked for some examples and the lack of results tells me it probably can't be done (first define a fixed width of 1px and then stretch sounds funny)
Return cropped image in xslt
Hi all,
Im new to Umbraco, and i have one issue.
I have image which i get with GetMedia() and would like to cropp it in xslt and set cropped value as src.
Is this possible and how?
(I found imageGen but free version doesnt have cropping possibility)
Thank you all.
Hi Zarko
I think you should have a look at this: http://our.umbraco.org/projects/backoffice-extensions/image-cropper (whatch the demonstration)
If you are using Umbraco v4.5 the datatype is already installed but you need to create it in the developer section. Just right click "datatypes" and pick "create". Give your cropper af name and select the image cropper datatype from the dropdown list.
/Jan
Hi Jan,
Thanks for your reply.
I'll take a look at that image-cropper. Anyway, i was hoping that cropping could be done in XSLT dynamically, without any user effort.
So far i didnt find any solution to this part.
Hi Zarko
Hmm...then I'm wondering if you could benefit from using the upload datatype. There you can actually specify thumbnail sizes. You can specify more than one.
What you need to do is to go to the developer section and select the upload datatype and then write the values you need in there. This i probably documented somewhere else also, but for now I can just remember you can see how to do it by having a look at Doug's slides from the uk festival: http://umbracoukfestival.co.uk/media/676/did%20you%20know%20-%20umbraco%20uk%20festival.pdf page 22.
Could this be what you're after?
/Jan
Use the ImageGen package to resize the images. It works better than the imagecropper as long as you want your image to be resized, and not cropped (unless you buy the pro version of ImageGen)
xslt example:
Hi Jan,
This looks very promissing! I just need to write xsl code to use cropped version when needed.
I'll let you know if i manage to get what i needed.
Thank you very much.
Here is a demo using imagecropper, though i should mention that we stopped using it because it has a lot of data-entry issues for content managers (crops don't get created untill you save the image at least twice, and all crops must be defined manually otherwise it takes the smallest possible area of the image, instead of the largest. Since this feature is caused by the way Umbraco works, it won't be fixed before Umbraco 5.0)
sample xslt:
It's not the cleanest way to do it, but it worked for our testing purposes before we abandoned the imagecropper untill Umbraco 5.0
Ahh... Upload datatype resizes image, and i need to crop it and use first couple pixels.
Im building a page header with image in middle, and i need to expand image edge color to the page edges. My initial idea is to repeat cropped image to the edges of page. I could do this also with a backround color if i could take it from first image pixel.
@Rik:
I need to crop image, so free ImageGen version could not help me.
Can't you do that with CSS alone? just use css sprites to only show the last pixel of an image and then repeat it as far as you want?
Hmm no i think its not possible. At least as i know.
I have big picture and can not tel div to repeat only part of it (1px) as backround. Please correct me if im wrong.
You're probably right, i looked for some examples and the lack of results tells me it probably can't be done (first define a fixed width of 1px and then stretch sounds funny)
Just to let you know, i found solution.
I created event AfterSave on media which saves cropped image version in same directory. Later i use this cropped image and repeat it as background.
Once again thx for effort and suggestions.
is working on a reply...