I've just transfered a site from one server to another (on the same type of hosting) and am using the section expand template for the Menu.
Now occasionally it gives this error, which goes away if I refresh the page. The menu stays there but it is pushed down by the error. It doesn't do it on the old site so can only assume something has gone strange in the transfer. Any ideas?
This is the sectionexpand template:string(144) "Smarty error: [in module_db_tpl:MenuManager;sectionexpand line 16]: syntax error: unrecognized tag 'while' (Smarty_Compiler.class.php, line 590)" string(145) "Smarty error: [in module_db_tpl:MenuManager;sectionexpand line 20]: syntax error: unrecognized tag '/while' (Smarty_Compiler.class.php, line 590)" string(144) "Smarty error: [in module_db_tpl:MenuManager;sectionexpand line 57]: syntax error: unrecognized tag 'while' (Smarty_Compiler.class.php, line 590)" string(145) "Smarty error: [in module_db_tpl:MenuManager;sectionexpand line 61]: syntax error: unrecognized tag '/while' (Smarty_Compiler.class.php, line 590)"
{* CSS classes used in this template:
#active - The active/current page
li#separator - To style the ruler for the separator
span.sectionheader - To style section header *}
{if $count > 0}
{assign var="prevdepth" value="1"}
{foreach from=$nodelist item=node}
{assign var="prevdepth" value=$prevnode->depth}
{if ($node->depth haschildren == "1")} {* bugfix if subitems were not shown in menu *}
{else}
{if $node->depth depth}
{while (($act_depth > 0) and ($collapseopened > 0))}
{assign var="act_depth" value=$act_depth-1}
{assign var="collapseopened" value=$collapseopened-1}
{/while}
{else}
{/if}
{/if}
{/if}
{if $node->type == 'separator'}
{else}
{if $node->current == true}
{else}
{/if}
id}"
{if $node->type != 'sectionheader'}
href="{$node->url}"
{if $node->target ne ""}
target="{$node->target}"
{/if}
{/if}
{if $node->haschildren == '1'}
{assign var="collapseopened" value=$collapseopened+1} onclick="expandcontent('sub{$node->id}')"
{else}
{/if} style="cursor:hand; cursor:pointer">
{if $node->type == 'sectionheader'}{/if}
{$node->menutext}
{if $node->type == 'sectionheader'}{/if}
{if $node->haschildren == '1'}id}" class="expand">{/if}
{/if}
{assign var="prevnode" value=$node}
{/foreach}
{if ($prevnode->haschildren == "1")} {* bugfix if subitems were not shown in menu *}
{else}
{if $prevnode->depth > 1}
{assign var="act_depth" value=$prevnode->depth-1}
{while (($act_depth > 0) and ($collapseopened > 0))}
{assign var="act_depth" value=$act_depth-1}
{assign var="collapseopened" value=$collapseopened-1}
{/while}
{else}
{/if}
{/if}
{/if}