---
title: "getChildPages"
canonical: "https://support.appfire.com/space/PSCONF/15306544/getChildPages"
format: markdown
---
> Macro (aura-html)

> Macro (table-plus)
> 
> |  |  |  |  |
> | --- | --- | --- | --- |
> | **Syntax** | getChildPages(parentId) | **Package** |  |
> | **Alias** |  | **Pkg Usage** |  |

## Description

> Macro (excerpt)
> 
> Get the list of child pages (direct children) for a selected page.

Get the list of child pages (direct children) for a selected page.

## Parameters

> Macro (table-plus)
> 
> | Parameter name | Type | Required | Description |
> | --- | --- | --- | --- |
> | parent ID | Number | Yes | ID of the selected page for which to direct child pages need to be retrieved. |

## Return Type

**Number []**

Ids of the child pages for the selected page.

## Example

```javascript
number [] children = getChildPages(11801);
for(number childPage in children) {
	%childPage%.labels += "newLabel";
}
```

## See also

> Macro (contentbylabel)