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.

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

How do I resize an image if...


Go to End


753 Views

Avatar
_Vince

Community Member, 165 Posts

24 September 2010 at 5:06pm

I need to resize images on a template.

The only problem is that the template is fed by the result of an SQLQuery, so all I have is a column with the ID number of the image, not the image object.

Is there anyway to access setWidth(), working back from the ID?