Standard data type attributes

Author Message

Stephen Paschall

Monday 13 October 2003 9:54:36 am

It would be nice if there was a list somewhere of the attributes of the standard data types that can be accessed through the template language. For example:

I added an ezimage element, id'ed by 'thumbnail', to the "content/file" class. If there is an image associated with a particular file, I'd like to display a particular section of my template; if not, I want to prevent that section from displaying and adding excess whitespace. I tried

...show=$node.object.data_map.thumbnail.filename...
...show=$node.object.data_map.thumbnail.original_filename...

and several variations on the above (e.g., not($node.object.data_map.thumbnail.filename|null()) ) but nothing appears to work. Granted, I'm not sure I fully understand how the object model in the templates relates to the PHP object model, but neither is there a great reference to this, and what information there was (in the old SDK reference) is unavailable now. Help!

David Syers

Monday 13 October 2003 10:33:30 am

If you are unsure of any attributes use "|attribute(show)"

ie.

{$node.object.data_map.thumbnail|attribute(show)}

will show you all of the values that are available for this object.

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 16:28:04
Script start
Timing: Jan 18 2025 16:28:04
Module start 'layout'
Timing: Jan 18 2025 16:28:04
Module start 'content'
Timing: Jan 18 2025 16:28:04
Module end 'content'
Timing: Jan 18 2025 16:28:04
Script end

Main resources:

Total runtime0.5162 sec
Peak memory usage4,096.0000 KB
Database Queries54

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0055 587.9141152.6250
Module start 'layout' 0.00550.0028 740.539139.4453
Module start 'content' 0.00830.5067 779.9844457.9141
Module end 'content' 0.51500.0012 1,237.89848.1641
Script end 0.5162  1,246.0625 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00300.5784160.0002
Check MTime0.00130.2514160.0001
Mysql Total
Database connection0.00070.129210.0007
Mysqli_queries0.478692.7181540.0089
Looping result0.00050.0991520.0000
Template Total0.486994.320.2434
Template load0.00180.342720.0009
Template processing0.485193.969020.2425
Template load and register function0.00020.030610.0002
states
state_id_array0.00130.253010.0013
state_identifier_array0.00110.206920.0005
Override
Cache load0.00150.2848130.0001
Sytem overhead
Fetch class attribute can translate value0.00050.100920.0003
Fetch class attribute name0.00100.194920.0005
XML
Image XML parsing0.00040.068420.0002
class_abstraction
Instantiating content class attribute0.00000.003720.0000
General
dbfile0.00060.1093100.0001
String conversion0.00000.002440.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
2content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
3content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/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: 8
 Number of unique templates used: 5

Time used to render debug report: 0.0001 secs