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.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Archive /

Our old forums are still available as a read-only archive.

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

Scaling images in ComplextTableField (CMS)


Go to End


6 Posts   2053 Views

Avatar
dashiel

Community Member, 13 Posts

9 May 2008 at 6:22pm

Edited: 09/05/2008 6:22pm

i have a ComplexTableField with two text columns and a single image column. i want the image column to show a preview/thumbnail/scaled version only. i know how to do this on the client side, but not sure on the CMS side.

cheers in advance.

Avatar
Ingo

Forum Moderator, 801 Posts

10 May 2008 at 11:29am

Avatar
Sam

Administrator, 690 Posts

10 May 2008 at 12:26pm

Do you mean in the CTF's pop-up window, or in the table itself?

Avatar
dashiel

Community Member, 13 Posts

10 May 2008 at 12:37pm

> Do you mean in the CTF's pop-up window, or in the table itself?

in the table itself

Avatar
Ingo

Forum Moderator, 801 Posts

10 May 2008 at 2:11pm

hm, don't think anybody tried this yet, but turns out its no problem :)

see http://pastie.caboo.se/194674

see http://doc.silverstripe.com/doku.php?id=gd&s=image and http://doc.silverstripe.com/doku.php?id=imageupload on how to create your own thumbnails (size, compression, padding, ...)

Avatar
dashiel

Community Member, 13 Posts

12 May 2008 at 1:00pm

thank you. this worked like a charm