[TYPO3-german] Page unterhalb einer Page

Christian Wolff chris at connye.com
Fri Apr 2 01:35:44 CEST 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Am 02.04.2010 00:03, schrieb Rainer Schleevoigt:
> Hi,
> 
> in einer SELECT-anfrage in php will ich testen, ob eine Seite unterhalb
> einer Seite liegt, ob sie also Kind, Enkel usw. ist …
> 
> Rainer
> 

hi Rainer,
jede seite hat ein feld pid (Parent Id) diese verweist auf die
übergeordnete seite.

ist die pid=0 dann ist die seite direct in der "root" (weltkugel)

kannst dich also über die pid's den pfad hochangeln bis entweder pid=0
ist oder die gesuchte seite in der rootline hochangelt.

so eine rootline läst sich leider nicht mit einer einzigen SQL query
abfragen.

guck mal in die typo3 api ich denke typo3 hat da bestimmt auch schon
interne funktionen die das tun (also dir eine rootline rausgeben)
http://typo3.org/fileadmin/typo3api-4.2.6/

gruss chris

- -- 
Christian Wolff // Berlin
http://www.connye.com

some projects:
http://richtermediagroup.com | http://titanic.de |
http://fairplay-homepage.de
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)

iEYEARECAAYFAku1LdAACgkQIcCaXPh/JHHvhQCfWPr5Fca2aR2hIrWt+8olTNJ5
QYEAn3YXq+ksS+d2csUEVz06eXLOq3Su
=QQ+4
-----END PGP SIGNATURE-----


More information about the TYPO3-german mailing list