Forums / Setup & design / read children of node_id

read children of node_id

Author Message

scrieler _

Thursday 24 April 2008 6:40:59 am

heya,

I need all children node_id's of one node_id
I wanna place one css to node id 178 and childrens

{switch match=$module_result.node_id}

{case match=178}
@import url({"stylesheets/mediendesign.css"|ezdesign});
{/case}
{case match=CHILDREN1}
@import url({"stylesheets/mediendesign.css"|ezdesign});
{/case}
{case match=CHILDREN2}
@import url({"stylesheets/mediendesign.css"|ezdesign});
{/case}

{/switch}

need a loop, but how?

Maxime Thomas

Thursday 24 April 2008 11:57:55 pm

Heya,

Can you be more explicit ? We don't understand what you want to do... So we can't help you.

Maxime Thomas
maxime.thomas@wascou.org | www.wascou.org | http://twitter.com/wascou

Company Blog : http://www.wascou.org/eng/Company/Blog
Technical Blog : http://share.ez.no/blogs/maxime-thomas

scrieler _

Friday 25 April 2008 12:06:25 am

hi Maxime Thomas,

my headerimage is set in my css files,
I want to change this by parent folders.

+Folder1
-Folder2
-Folder3
+Folder4
-Folder5
-Folder6

if I click on Folder1, Folder2 or Folder3 I want to load css file 1
it have to be active for all 3 folders, same in all other groups.
I want to define 1 css file for one parent.

Xavier Serna

Friday 25 April 2008 12:44:33 am

Supposing that folder1 and folder4 are at the same depth level, you only need to check for that in the node path array to know the current tree you are browsing and set the correct css for it.
As an example, for folder1, folder2 and folder3, the path element 2 will be always the same.

hth!

--
Xavier Serna
eZ Publish Certified Developer
Departament de Software
Microblau S.L. - http://www.microblau.net
+34 937 466 205

scrieler _

Friday 25 April 2008 2:39:03 am

ok, right, but how can i check it for my switch script?
$module_result.<path>=folder1>