Forums / Install & configuration / sidemenu crashed after code before - closed

sidemenu crashed after code before - closed

Author Message

scrieler _

Friday 28 March 2008 12:52:07 am

hello, after written my code before the sidemenu in pagelayout.tpl
my sidemenu cant view...

{* Billboard *}
{def $pagelayout_node=fetch(content,node,hash(node_id,$module_result.node_id))}
{if $pagelayout_node.object.data_map.billboard.has_content}
<div class="attribute-billboard">
{content_view_gui view=billboard content_object=$pagelayout_node.object.data_map.billboard.content}
</div>
{/if}
{undef}
{* Billboard end *}

-----------------------

{* Billboard *}
{let $pagelayout_node=fetch(content,node,hash(node_id,$module_result.node_id))}
{if $pagelayout_node.object.data_map.billboard.has_content}
<div id="billboard">
{content_view_gui view=billboard content_object=$pagelayout_node.object.data_map.billboard.content}
</div>
{/if}
{/let}
{* Billboard end *}

it runs, dont know my mistake..

André R.

Friday 28 March 2008 3:21:25 am

I guess everything under -------- is the update to your post (next time, just reply instead).
You mistake is probably {undef}, witch undefines every variable in the current/same namespace (basically all variables earlier set with def).
So you should have written : {undef $pagelayout_node}

http://ez.no/doc/ez_publish/technical_manual/4_0/reference/template_functions/variables/undef

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

scrieler _

Friday 28 March 2008 4:56:46 am

ok, thanks to u, havent see it, that the variable needed in other functions.

eZ debug

Timing: Jan 18 2025 19:39:46
Script start
Timing: Jan 18 2025 19:39:46
Module start 'content'
Timing: Jan 18 2025 19:39:46
Module end 'content'
Timing: Jan 18 2025 19:39:46
Script end

Main resources:

Total runtime0.0310 sec
Peak memory usage4,096.0000 KB
Database Queries4

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0073 587.8672180.8047
Module start 'content' 0.00730.0114 768.671993.9609
Module end 'content' 0.01880.0122 862.632870.7031
Script end 0.0309  933.3359 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00268.2495120.0002
Check MTime0.00123.8200120.0001
Mysql Total
Database connection0.00072.146710.0007
Mysqli_queries0.003210.307640.0008
Looping result0.00000.058520.0000
Template Total0.011737.810.0117
Template load0.00082.702410.0008
Template processing0.010935.088510.0109
Override
Cache load0.00061.968910.0006
General
dbfile0.00061.9404100.0001
String conversion0.00000.018530.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/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