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.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Decorating Image - extra cms fields

Go to End

3 Posts   970 Views


Community Member, 9 Posts

27 May 2012 at 6:20am

I want to add some extra fields to Image class - mainly for translations.

I guess it shouldn't be done by using updateCMSFields() function. It didn't work for me.


Forum Moderator, 5523 Posts

27 May 2012 at 12:18pm

updateCMSFields should work on any DataObject subclass (this includes Image). Make sure you've applied the decorator the image. Try apply your decorator to File and see if updateCMSFields works then.


Community Member, 9 Posts

31 May 2012 at 5:26am

It works on File class, and it should be enough for translating purposes.
Unfortunatelly, it still doesn't work for Image class.