Fetching images from Media library

Author Message

DeAndre Johnson

Thursday 23 July 2009 10:51:54 am

I have a block that I want to create a carousel from images that I uploaded to my Media Library section. These are standalone images created with image class. I used this code but it doesn't show images:

{attribute_view_gui attribute=$used_node.object.data_map.image image_class= "large"}

Does anyone know what is correct why to fetch these images?

Thanks

DeAndre

I am, because I choose to be!

John Moritz

Thursday 23 July 2009 12:28:11 pm

I am doin it like this:

{def $my_node=fetch( 'content', 'node', hash( 'node_id', $nodeID ) )}
{attribute_view_gui attribute=$my_node.data_map.image image_class=large}

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

Main resources:

Total runtime0.0151 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.0066 587.9141152.6250
Module start 'layout' 0.00660.0027 740.539139.4453
Module start 'content' 0.00930.0039 779.984489.3359
Module end 'content' 0.01320.0018 869.320330.3047
Script end 0.0150  899.6250 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002415.6781140.0002
Check MTime0.00127.6538140.0001
Mysql Total
Database connection0.00149.557010.0014
Mysqli_queries0.002516.404930.0008
Looping result0.00000.087110.0000
Template Total0.001510.210.0015
Template load0.00085.617710.0008
Template processing0.00074.507710.0007
Override
Cache load0.00064.064410.0006
General
dbfile0.00021.561280.0000
String conversion0.00000.033240.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