Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

interactive cropping


Go to End
Reply


20 Posts   4770 Views

Avatar
swaiba

Forum Moderator, 1799 Posts

15 October 2011 at 2:27am

@Xananax Prozaxx

I know exactly what you mean - I am ofcourse waiting to see what SS3 brings with it's redeign of the admin section - hopefully this will make cusomization easier.

In my expiernce most things can go into the Pages or DataObject with the use of the LiteralField, then is something still demands complete control I subclass LeftAndMain and then create a template for the left and the main - then treat as a regular page (still use ajax for most things...)

Avatar
brice

Community Member, 51 Posts

22 August 2012 at 4:32pm

We had this need too. The quickest way was to write a plugin -- as the Pixlr one (once workinging) seemed a bit overkill, and no others appeared.

See https://github.com/briceburg/silverstripe-uploaldify-jcrop

It gives you a "crop" button next to detach / delete permananetly in the Uploadify form, and loads a JCrop enabled image that's scaled to the modal when clicked.

WARNING; this has been only tested with a DataObjectManager popup under SilverStipe 2.4 and also has an issue where the browser caches the CMSThumbnail && doesn't instantly show you the cropped image for in.

Hope other SSers find it useful.

Avatar
JonoM

Community Member, 103 Posts

19 June 2013 at 7:05am

I've released a simple module for improving automatic cropping in SilverStripe 3: https://github.com/jonom/silverstripe-focuspoint

Basically, when you edit an image in the CMS there is a new field that lets you select a point on the image as the focus point - i.e someone's face. Then instead of using CroppedImage in your templates you use CroppedFocusedImage, and the image is cropped with a bias towards keeping the focus point in the center of the image, rather than always cropping from the centre.

Feedback, suggestions and pull requests welcome, hope someone finds it useful :)

Avatar
Terry Apodaca

Community Member, 109 Posts

20 June 2013 at 10:08am

Good Job @JonoM!!! That's a cool feature!

@brice, any chance you are going to update your plugin for 3.0? or release a version for 3.0? I've been wanting a jcop plugin for a long time, just haven't had a chance to build one.

Go to Top