eZ 3.1.0.2 : embed.tpl -> differents images cases

Author Message

laurent le cadet

Thursday 19 June 2003 12:54:08 am

This is the "original" template wich show images in the demo version :

{let image_variation="false"
align="center"
href=''}

{section show=is_set($attribute_parameters.size)}
{set image_variation=$object.data_map.image.content[$attribute_parameters.size]}
{section-else}
{set image_variation=$object.data_map.image.content["medium"]}
{/section}

{section show=is_set($attribute_parameters.align)}
{set align=$attribute_parameters.align}
{section-else}
{set align="center"}
{/section}

{section show=is_set($attribute_parameters.href)}
{set href=$attribute_parameters.href}
{section-else}
{set href=""}
{/section}

{switch match=$align}
{case match="left"}
<div class="imageleft">
{section show=$href}<a href={$href|ezurl}>{/section}
<img src={$image_variation.full_path|ezroot} />
{section show=$href}</a>{/section}

<div style="width: {$image_variation.width}px;">
{$object.data_map.caption.content.output.output_text}
</div>
</div>
{/case}
{case match="right"}
<div class="imageright">
{section show=$href}<a href={$href|ezurl}>{/section}
<img src={$image_variation.full_path|ezroot} />
{section show=$href}</a>{/section}

<div style="width: {$image_variation.width}px;">
{$object.data_map.caption.content.output.output_text}
</div>
</div>
{/case}
{case}
<div class="imagecenter">
{section show=$href}<a href={$href|ezurl}>{/section}
<img src={$image_variation.full_path|ezroot} />
{section show=$href}</a>{/section}

<div style="width: {$image_variation.width}px;">
{$object.data_map.caption.content.output.output_text}
</div>
</div>
{/case}
{/switch}

{/let}

I would like to show images in original size without the line for the caption.
I think it's this one :

<div style="width: {$image_variation.width}px;">
{$object.data_map.caption.content.output.output_text}
</div>

So I tryied this way (this few lines just before the last {/let} of the previous code):

{switch match=$image_variation}
{case match="original"}
<img src={$image_variation.full_path|ezroot} />
{/case}
{/switch}

But it don't work. Someone can help me ?

Tor Olav Steinsvoll

Thursday 24 July 2003 3:42:42 am

Log in to admin and check the full.tpl and what template-override the images got.

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

Main resources:

Total runtime1.2049 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.0070 589.4766152.6406
Module start 'layout' 0.00700.0030 742.117239.4766
Module start 'content' 0.01001.1935 781.5938511.5391
Module end 'content' 1.20340.0014 1,293.132812.1250
Script end 1.2048  1,305.2578 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.2577160.0002
Check MTime0.00130.1077160.0001
Mysql Total
Database connection0.00080.069710.0008
Mysqli_queries1.150595.4856540.0213
Looping result0.00060.0487520.0000
Template Total1.163896.620.5819
Template load0.00200.163420.0010
Template processing1.161896.428920.5809
Template load and register function0.00010.009510.0001
states
state_id_array0.00160.130910.0016
state_identifier_array0.00230.192620.0012
Override
Cache load0.00170.1443700.0000
Sytem overhead
Fetch class attribute can translate value0.00050.041220.0002
Fetch class attribute name0.00100.083030.0003
XML
Image XML parsing0.00060.046220.0003
class_abstraction
Instantiating content class attribute0.00000.000430.0000
General
dbfile0.00080.0676160.0001
String conversion0.00000.000740.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
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
2content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
13content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
11content/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: 29
 Number of unique templates used: 6

Time used to render debug report: 0.0002 secs