You are here: Re: Adjacency List Model Hierarchical Structure into HTML Structured List « PHP Programming Language « IT news, forums, messages
Re: Adjacency List Model Hierarchical Structure into HTML Structured List

Posted by Rik on 06/06/07 17:53

On Wed, 06 Jun 2007 19:47:42 +0200, Rik <luiheidsgoeroe@hotmail.com> wro=
te:

> On Wed, 06 Jun 2007 19:07:30 +0200, Rik <luiheidsgoeroe@hotmail.com> =

> wrote:
>> $where =3D ($id =3D=3D 0) ? ' IS NULL ': ' id =3D '.intval($pare=
nt);
>
> Obviously:
> $where =3D ($id =3D=3D 0) ? ' IS NULL ': ' =3D '.intval($parent);

DOH!!!!
Obviously:
$where =3D ($parent =3D=3D 0) ? ' IS NULL ': ' =3D '.intval($parent);

And use it without arguments to get the tree from the root:

treelist();

Only give arguments (the first being the id which you'd like to expand) =
if =

you're only interested in a sub-tree.
-- =

Rik Wasmus

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация