# getCurrentPage

## Description

Returns the name of the current page the user is on.

## Input / Parameter

N/A

## Output

| Description                           | Output Type |
| ------------------------------------- | ----------- |
| Returns the name of the current page. | String/Text |

## Callback

N/A

## Video

Coming Soon.

## Example

The user wants to get the name of the current page they are on.

### Steps

| No. | Description                                                                                                                                                                                                         |                                                                                                                                            |
| --- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| 1.  | ![](https://399701567-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwmJ1RKjM2uNFaL6fO3Xu%2Fuploads%2Fgit-blob-9492deeab0d82bdb1e8ec4173f7d3fa51474de93%2FgetCurrentPage-step-1.png?alt=media) | Drag a button to a page in the mobile designer. Select the event `click` for the button and drag the `console` function to the event flow. |
| 2.  | ![](https://399701567-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwmJ1RKjM2uNFaL6fO3Xu%2Fuploads%2Fgit-blob-bcda2f0add49cc74b9e8c07d397d45e96e569535%2FgetCurrentPage-step-2.png?alt=media) | Select the `function` parameter input type for the value parameter.                                                                        |
| 3.  | ![](https://399701567-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FwmJ1RKjM2uNFaL6fO3Xu%2Fuploads%2Fgit-blob-e57f931eac8f1b4d56d9a0bc24b774c119be5898%2FgetCurrentPage-step-3.png?alt=media) | Drag the `getCurrentPage` function to the node in the subflow.                                                                             |

### Result

When the button is pressed, the console will show the name of the current page.

## Links
