eZ OE 5.0: Subtitle / Caption for Images

Author Message

Michael Fürst

Tuesday 07 April 2009 12:59:30 am

Hi there, again me ;)

Another question to eZ OE 5.0 (maybe this is also important for other users):
Is there a way to add a Caption / Title / Subtitle for an Image when it's inserted? So that this caption is stored as $object attribute and can be accessed in the template.

<b>For example:</b>
Imagine you have an image of the Eiffel Tower in Paris in the eZ Media Library. The Editor adds this Image to the first Article "Nightlife in Paris" and wants to add the subtitle / caption "<i>The Eiffel Tower and his beautiful illumination at night</i>" wich is shown directly bellow the image in the article.

Some weeks later the Editor writes another article about resturants in Paris an uses the exactly same image of the Eiffel Tower from the eZ Media Library again. But now he wants to add the caption "<i>The great Tower Restaurant in the Eiffel Tower is a must</i>" bellow the image.

<b>Problem:</b>
The easiest solution would be to add an Attribute "Subtitle / Caption" to the image class and the editor has to add the caption when he adds the image to the Media Library. BUT: As we know from our editors, many images are used not only one time and in one article - for example they use very often symbolic images (like the tower image) for many articles. And in each article there should be another caption.

So the only way to solve this problem would be, that the editor adds the caption during the selection process in the eZ OE 5.0 - that's already possible when uploading a new image but not when choosing an existing image object from the media library.

<b>The question is:</b>
Has anyone an idea how to add an additional field "Subtitle / Caption" to the embedded image selection tool of eZ OE 5.0 so that this value is available as $object variable in the template? (like Offset or Limit)

Thanks & regards,
Michael

Michael Fürst

Wednesday 29 April 2009 6:37:42 am

Hi Guys,

Sorry, I've to push this topic up.
If noone knows a solution - how are you handling this problem? Maybe there is another way i don't see at the moment.

Regards,
Mike

André R.

Wednesday 29 April 2009 7:18:30 am

Use custom attributes, look in content.ini and optionally ezoe_attributes.ini to see how and what you can do.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

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 15:05:50
Script start
Timing: Jan 18 2025 15:05:50
Module start 'layout'
Timing: Jan 18 2025 15:05:50
Module start 'content'
Timing: Jan 18 2025 15:05:51
Module end 'content'
Timing: Jan 18 2025 15:05:51
Script end

Main resources:

Total runtime1.3200 sec
Peak memory usage4,096.0000 KB
Database Queries57

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0056 588.0313152.6406
Module start 'layout' 0.00560.0036 740.671939.4766
Module start 'content' 0.00911.3094 780.1484556.2891
Module end 'content' 1.31850.0014 1,336.437512.1250
Script end 1.3199  1,348.5625 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.2334160.0002
Check MTime0.00130.0958160.0001
Mysql Total
Database connection0.00070.055510.0007
Mysqli_queries1.266895.9717570.0222
Looping result0.00060.0456550.0000
Template Total1.281997.120.6410
Template load0.00180.132920.0009
Template processing1.280296.983620.6401
Template load and register function0.00010.007110.0001
states
state_id_array0.00130.097710.0013
state_identifier_array0.00170.131320.0009
Override
Cache load0.00150.1104270.0001
Sytem overhead
Fetch class attribute can translate value0.00080.059120.0004
Fetch class attribute name0.00090.067550.0002
XML
Image XML parsing0.00110.080020.0005
class_abstraction
Instantiating content class attribute0.00000.001060.0000
General
dbfile0.00100.0785230.0000
String conversion0.00000.000840.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
3content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
10content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
7content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 25
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs