Wednesday 30 April 2003 3:46:38 pm
I have been looking into this further and it appears I answered my own question (forgive me for being a Newbie - my actual profession is as an accountant) This is what I have come up with ( parent_node_id,2 is my root folder of the enire site - I then have 11 different sections and each folder in the root is assigned to a different section)
IE,
Root
Folder1 (section1)
- Sub pages and folders
Folder2 (section2)
- Sub pages and folders
.
.
Folder11 (Section11) -Sub pages and folders I used to need 11 templates (one for each section) that all share common script except for references relating to images, and menu bars etc. I can now have 1 main template for all 11 and use variables throughout based on the uniques section id's. A specific example is the top_cat variable in the nav tree menu . {let name=Child children=fetch('content','list',hash(parent_node_id,2))}
{section loop=$:children}
{section show=eq $Child:item.object.section_id,$DesignKeys:used.section)}
{$Child:item.node_id}
{/section}
{/section} {/let} I am stuck on how to this variable {Child:itm.node_id} to the variable top_cat that is used in the nav tree menu?? I have tried set and top_cat= but it does not seem to work - If you have any suggestions please let me know I seem to be having difficulty understanding the way you pass variables. I am going to move on for now to sort out how to loop through the nav tree menu based on a count of how deep the folder structure is - rather than having to pre-define all the levels manually. This will include a way to show the active items with varying css applied based on that depth. On another note I have modified the the sitemap to always show the node_id to make things easier to understand - this is a simple mod I can post for any new people if they want - it helps understand the site structure. jonathan
|