fetch trouble: Expected whitespace, got: 'fetch(content, node, hash{node_id, 62))}'

Author Message

Gabriel Ambuehl

Saturday 14 June 2003 2:14:53 am

I wanted to display the content of node 62 on some place in my pagelayout. After some RTFM I figured that the following should work:

{let leftbox=fetch(content, node, hash{node_id, 62))}
{node_view_gui content_object=$leftbox}
{/let}

But eztemplate complains::
Expected whitespace, got: 'fetch(content, node, hash{node_id, 62))}'

Never mind that some lines above, I fetch the children of the root node with
{let children=fetch('content',list,hash(parent_node_id,2))}
and that works perfectly.

Oh, template compiling has been turned off for the time being.

Visit http://triligon.org

Gabriel Ambuehl

Sunday 15 June 2003 1:55:58 am

For reasons beyond my understanding,

{let children=fetch(content,node,hash(node_id,62))}
{node_view_gui view=full content_node=$children}
{/let}

will works just perfectly.

Visit http://triligon.org

Paul Borgermans

Sunday 15 June 2003 3:10:35 am

>For reasons beyond my understanding,
>{let children=fetch(content,node,hash(node_id,62))}
>{node_view_gui view=full content_node=$children}
>{/let}
>will works just perfectly.

Hmm?

hash{node_id, 62) is a typo, hash(node_id,62) is correct.

--paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Gabriel Ambuehl

Sunday 15 June 2003 10:10:27 am

Oh dear. So there must not be any whitespace in the hash :-(

Visit http://triligon.org

Jan Borsodi

Sunday 15 June 2003 12:46:36 pm

Whitespace was not the problem, you had a { (curly brace) instead of a ( (parenthesis).

--
Amos

Documentation: http://ez.no/ez_publish/documentation
FAQ: http://ez.no/ez_publish/documentation/faq

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 11:13:55
Script start
Timing: Jan 18 2025 11:13:55
Module start 'layout'
Timing: Jan 18 2025 11:13:55
Module start 'content'
Timing: Jan 18 2025 11:13:56
Module end 'content'
Timing: Jan 18 2025 11:13:56
Script end

Main resources:

Total runtime0.7870 sec
Peak memory usage4,096.0000 KB
Database Queries65

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0065 588.4063152.6875
Module start 'layout' 0.00650.0024 741.093839.5234
Module start 'content' 0.00890.7767 780.6172600.4297
Module end 'content' 0.78560.0014 1,381.046912.0625
Script end 0.7870  1,393.1094 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00360.4540160.0002
Check MTime0.00140.1763160.0001
Mysql Total
Database connection0.00130.171510.0013
Mysqli_queries0.728392.5455650.0112
Looping result0.00090.1168630.0000
Template Total0.757796.320.3789
Template load0.00210.263920.0010
Template processing0.755796.016820.3778
Template load and register function0.00020.021010.0002
states
state_id_array0.00140.179010.0014
state_identifier_array0.00100.129120.0005
Override
Cache load0.00180.2282340.0001
Sytem overhead
Fetch class attribute can translate value0.00040.055130.0001
Fetch class attribute name0.00220.275370.0003
XML
Image XML parsing0.00110.143230.0004
class_abstraction
Instantiating content class attribute0.00000.002170.0000
General
dbfile0.00120.1489240.0000
String conversion0.00000.001340.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
5content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
9content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
5content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
2content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 23
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs