dynamic text in images with ezimagemanager

Author Message

christian stampf

Friday 09 July 2004 6:34:42 am

i would like to write some dynamic text into images using imagemagicks convert or the respecitve ezimagemanager function.
the text is coming from some fields of a customized "product" class and should show up inside the image.

for example: the product number and product name.

i checked out ezimagemanager but it seems that i would have to generate a new rule for every single image as the text is dynamic (parameter based).

does anyone have a clue how to realize this?

Ekkehard Dörre

Sunday 11 July 2004 2:28:51 am

Hi,

look at http://ez.no/ez_publish/documentation/development/libraries/ez_template/operators/image_handling
this example:

{image("church",
       imagefile('var/cache/texttoimage/church.jpg'),
       array('eZ publish'|texttoimage,
             hash(transparency,0.8,
                  halign,right,
                  valign,top)))}

You can take the background image (e.g. your product image) dynamically and take the text out of database like this

{$node.name|wash|texttoimage(arial)}

Greetings ekke

http://www.coolscreen.de - Over 40 years of certified eZ Publish know-how: http://www.cjw-network.com
CJW Newsletter: http://projects.ez.no/cjw_newsletter - http://cjw-network.com/en/ez-publ...w-newsletter-multi-channel-marketing

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 05:26:35
Script start
Timing: Jan 31 2025 05:26:35
Module start 'layout'
Timing: Jan 31 2025 05:26:35
Module start 'content'
Timing: Jan 31 2025 05:26:35
Module end 'content'
Timing: Jan 31 2025 05:26:35
Script end

Main resources:

Total runtime0.0320 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0138 588.2578151.2266
Module start 'layout' 0.01380.0040 739.484436.6797
Module start 'content' 0.01790.0121 776.164190.2813
Module end 'content' 0.03000.0020 866.445329.9922
Script end 0.0320  896.4375 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00309.3091140.0002
Check MTime0.00123.6885140.0001
Mysql Total
Database connection0.00123.675110.0012
Mysqli_queries0.009429.498930.0031
Looping result0.00000.052910.0000
Template Total0.00123.910.0012
Template load0.00102.976710.0010
Template processing0.00030.868110.0003
Override
Cache load0.00061.964110.0006
General
dbfile0.00041.262080.0001
String conversion0.00000.030540.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