Fetch problem... Depth...

Author Message

Nebojsa Eric

Thursday 18 May 2006 3:59:08 am

What am I doing wrong?

{let name=somename children=fetch( content, list, hash
(parent_node_id, 90,
sort_by, array( 'attribute', false(), 'someclass/date' ),
depth, 5,
limit, 5,
class_filter_type, include,
class_filter_array, array( 'someclass' ) )) }

{section loop=$:children}
...
...

This code returns nothing... It should return all objects under the main node 90 until depth 5 of class someclass.

Łukasz Serwatka

Thursday 18 May 2006 4:12:05 am

Depth parameter does not work with "list", try with "tree". List fetched objects till depth 1.

http://ez.no/doc/ez_publish/technical_manual/3_7/reference/modules/content/fetch_functions/tree

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Nebojsa Eric

Thursday 18 May 2006 4:47:29 am

Thank you Lukasz. Tree works.

I`m trying this with list and tree since morning and I finally found what is wrong.

Can`t use .... fetch( content, tree, hash
(parent_node_id...

Syntax must be .... fetch( content, tree, hash(parent_node_id...

"hash" and "(" should be together. Otherwise, not working. There was a problem. :)

Łukasz Serwatka

Thursday 18 May 2006 4:59:22 am

Good to see that works. Always keep debug output enabled when you changing templates. You will save a lot of time ;)

Cheers,
Luke

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

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

Main resources:

Total runtime0.7143 sec
Peak memory usage4,096.0000 KB
Database Queries60

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0056 590.1484152.6094
Module start 'layout' 0.00560.0029 742.757839.4297
Module start 'content' 0.00850.7041 782.1875558.3359
Module end 'content' 0.71260.0017 1,340.523412.1797
Script end 0.7142  1,352.7031 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.4380160.0002
Check MTime0.00130.1829160.0001
Mysql Total
Database connection0.00070.103210.0007
Mysqli_queries0.655191.7089600.0109
Looping result0.00050.0741580.0000
Template Total0.684795.920.3424
Template load0.00220.309720.0011
Template processing0.682595.547120.3413
Template load and register function0.00020.024510.0002
states
state_id_array0.00080.111310.0008
state_identifier_array0.00110.157520.0006
Override
Cache load0.00190.2650340.0001
Sytem overhead
Fetch class attribute can translate value0.00050.070720.0003
Fetch class attribute name0.00130.186960.0002
XML
Image XML parsing0.00300.422120.0015
class_abstraction
Instantiating content class attribute0.00000.002580.0000
General
dbfile0.00330.4687240.0001
String conversion0.00000.001240.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
4content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
7content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
3content/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: 20
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs