Working with images

Author Message

Alejandro Dominguez

Tuesday 25 January 2011 1:54:01 am

Hello folks,

I have a doubt working with images in an eZ class for a news website. The news class have an image attribute to upload the main image.

If I want to resize the image for the differents views of my article, should I do it before or after upload it? For example I want that new in a blog view with an image of 221x149 px and I also want to use that new in a column with less width.

Can anybody help me?

Cheers

Sylvain Guittard

Tuesday 25 January 2011 2:41:18 am

Hi,

It's better to upload an image with a maximum resolution and let ez publish manage image sizes.

Check the doc:

http://doc.ez.no/eZ-Publish/Technical-manual/4.x/Reference/Configuration-files/image.ini/AliasSettings/AliasList

and define different sizes for your website

http://www.vignevin-epicure.com
http://twitter.com/vignevinEPIcure

Bertrand Dunogier

Tuesday 25 January 2011 2:47:05 am

You don't need to resize your images yourself. Just upload the largest quality image you have, and the image system will take care of the rest, based on images aliases definitions: http://doc.ez.no/eZ-Publish/Technical-manual/4.x/Reference/Configuration-files/image.ini/AliasSettings/AliasList

I'm not sure there is a dedicated documentation for it though, but you can easily read the comments in image.ini and ask here for more information.

Bertrand Dunogier
eZ Systems Engineering, Lyon
http://twitter.com/bdunogier
http://gplus.to/BertrandDunogier

Alejandro Dominguez

Wednesday 26 January 2011 12:01:14 am

Wow! This is an amazing feature! It was what I need!

Thanks Sylvain and Bertrand for your answer!!!

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 11:21:25
Script start
Timing: Jan 18 2025 11:21:25
Module start 'layout'
Timing: Jan 18 2025 11:21:25
Module start 'content'
Timing: Jan 18 2025 11:21:25
Module end 'content'
Timing: Jan 18 2025 11:21:25
Script end

Main resources:

Total runtime0.0327 sec
Peak memory usage4,096.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0080 587.7891152.6094
Module start 'layout' 0.00800.0057 740.398439.4375
Module start 'content' 0.01370.0166 779.835993.2891
Module end 'content' 0.03040.0023 873.125034.2891
Script end 0.0326  907.4141 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.003711.2583140.0003
Check MTime0.00195.8849140.0001
Mysql Total
Database connection0.00061.876310.0006
Mysqli_queries0.006018.245930.0020
Looping result0.00000.073710.0000
Template Total0.00195.710.0019
Template load0.00092.739610.0009
Template processing0.00102.935210.0010
Override
Cache load0.00061.971110.0006
General
dbfile0.004614.004480.0006
String conversion0.00000.060640.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0002 secs