contenido\includes\functions.api.category.php
Project:
Contenido Content Management System
Description: Contenido Category API functions
Requirements:
- Author
- Timo A. Hummel
- Con_php_req
- 5.0
- Copyright
- four for business AG
- License
- http://www.contenido.org/license/LIZENZ.txt
- Link
- http://www.4fb.de
- Link
- http://www.contenido.org
- Package
- Contenido Backend includes
- Since
- file available since contenido release <= 4.6 {@internal created 2003-08-08 modified 2008-06-25, Frederic Schneider, add security fix $Id: functions.api.category.php 597 2008-07-11 11:32:27Z dominik.ziegler $: }}
- Version
- 1.4.0
Functions

capi_cat_getlevelnode( $idcat, $minLevel = 0) : int
capiCatGetLevelNode: Seeks through the category tree and returns the node on a specific level.
Example:
- Category A (15) |-+ News (16) | |- News A (17)
- Category B (18) |-+ Internal (19)
Given you are in the leaf "News A" (idcat 17), and you want to get out in which "main" tree you are, you can call the function like this:
capi_cat_getlevelnode(17,1);
The example would return "Category A" (idcat 15). If you specify an invalid level, the results are undefined.
Name | Type | Description |
---|---|---|
$idcat | ||
$minLevel | int The level to extract |
Type | Description |
---|---|
int | The category node on a specific level |