Forums / Developer / children id list / Comment44175

Author Topic

Aladdin Mouhaimeed

Tuesday 13 September 2005 9:53:03 am

Comment44175

Hi :
i have used this code for doing that:

$var = call_user_func_array( array( new eZContentFunctionCollection(), 'fetchObjectTree' ),
array('parent_node_id' => 59,
'only_translated' => false,
'language' => false,
'offset' => false,
'limit' => false,
'depth' => 100,
'depth_operator' => "le",
'class_id' => false,
'attribute_filter' => false,
'extended_attribute_filter' => false,
'class_filter_type' => false,
'class_filter_array' => false,
'group_by' => false,
'main_node_only' => false,
'ignore_visibility' => false,
'limitation' => null,
'as_object' => null ) );
$var = isset( $var['result'] ) ? $var['result'] : null;
echo $var;
while ( is_object( $var ) and method_exists( $var, 'templateValue' ) );
$v= $var[1];
echo $v->attribute('node_id');

and that makes us getting the ids of children nodes, so is it good way?or there is cleaner one?