Sizing image by percentage instead of by set pixel value

Author Message

Alex Jones

Wednesday 23 July 2003 6:29:39 am

My earlier question along these lines has gotten buried and as I still really need help with this I am posting it once more.
How can I set up eZ publish to re-size the images based on set percentages instead of set pixel values?
For example:
small: 25% of original image size
medium: 50% of original image size
large: 100% of original image size

I know this is possible with GD2 (which is what I am using); but for the life of me I cannot determine what change needs to be made to put it into place. When using the various imagecopy* commands in PHP the only difference seems to be adding a % after the numeric value to indicate it should be a percentage.

I could really use some help on this one.

Alex

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>

Alex Jones

Wednesday 06 August 2003 9:23:06 am

Anyone? Please?

Alex

Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]

<i>When in doubt, clear the cache.</i>

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 31 2025 02:57:56
Script start
Timing: Jan 31 2025 02:57:56
Module start 'layout'
Timing: Jan 31 2025 02:57:56
Module start 'content'
Timing: Jan 31 2025 02:57:56
Module end 'content'
Timing: Jan 31 2025 02:57:56
Script end

Main resources:

Total runtime0.0408 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.0086 589.3750151.2422
Module start 'layout' 0.00870.0074 740.6172220.7500
Module start 'content' 0.01610.0226 961.3672997.8672
Module end 'content' 0.03870.0021 1,959.234429.9922
Script end 0.0408  1,989.2266 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00297.1850140.0002
Check MTime0.00112.7498140.0001
Mysql Total
Database connection0.00122.985310.0012
Mysqli_queries0.005914.573430.0020
Looping result0.00000.083010.0000
Template Total0.00163.910.0016
Template load0.00122.887710.0012
Template processing0.00040.950910.0004
Override
Cache load0.00071.806510.0007
General
dbfile0.00297.152380.0004
String conversion0.00000.028140.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.0001 secs