# Get Input Value

{% hint style="info" %}
**Block Information**

Available in: Page Flow

Toolbox Category: Input

Block Type: [Output](https://docs.zingy.ai/app-editor/block-anatomy#output-block)

Output Type: [*text*](https://docs.zingy.ai/app-editor/page-flow/references/value-types)
{% endhint %}

**`Get Input Value`** is an [output block](https://docs.zingy.ai/app-editor/block-anatomy#output-block) that allows you to retrieve the value of [Input](https://docs.zingy.ai/app-editor/page-editor/built-in-elements/input), [Dropdown](https://docs.zingy.ai/app-editor/page-editor/built-in-elements/dropdown) and [Multi-line](https://docs.zingy.ai/app-editor/page-editor/built-in-elements/multi-line) elements on a page or form. The output is of type [*text*](https://docs.zingy.ai/app-editor/page-flow/references/value-types) and is compatible with [Value Parameters](https://docs.zingy.ai/app-editor/block-anatomy#value-parameters) of type [*text*](https://docs.zingy.ai/app-editor/page-flow/references/value-types) or of type [*any*](https://docs.zingy.ai/app-editor/page-flow/references/value-types).

{% hint style="success" %}
Refer to the [Get Input Value in Data Design](https://docs.zingy.ai/app-editor/page-flow/toolbox-blocks/get-input-value-in-data-design) block for dynamically generated content.
{% endhint %}

The block comes in two modes which are discussed below.

## Mode 1 <a href="#mode-1" id="mode-1"></a>

<div align="left"><figure><img src="https://3401585094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmnBepgycwgisXr9ya1N4%2Fuploads%2Fa47xQvLxIPpoRAmlGDXU%2Fimage.png?alt=media&#x26;token=20c5ef7b-a90b-43d5-8c9d-89d596dbb862" alt="" width="275"><figcaption><p>Get Input Value (Mode 1)</p></figcaption></figure></div>

The Mode 1 version of the Get Input Value block consists of a [Selectable Input](https://docs.zingy.ai/app-editor/block-anatomy#selectable-input) to choose the element you want to get the value of.

## Mode 2 <a href="#mode-2" id="mode-2"></a>

<div align="left"><figure><img src="https://3401585094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmnBepgycwgisXr9ya1N4%2Fuploads%2FCZJK6zukCKTlCSBfLyOE%2Fimage.png?alt=media&#x26;token=7f120b00-191d-4a27-966a-2ca55ff5183f" alt="" width="210"><figcaption><p>Get Input Value (Mode 2)</p></figcaption></figure></div>

The Mode 2 version of the Get Input Value block consists of a [Value Parameter](https://docs.zingy.ai/app-editor/block-anatomy#value-parameters) that accepts either a [*text*](https://docs.zingy.ai/app-editor/page-flow/references/value-types) value in the form of a [CSS Selector](https://developer.mozilla.org/en-US/docs/Learn/CSS/Building_blocks/Selectors) or an [*element*](https://docs.zingy.ai/app-editor/page-flow/references/value-types) value[.](https://developer.mozilla.org/en-US/docs/Learn/CSS/Building_blocks/Selectors) The Element block comes pre-attached for your convenience but can be removed and customized.

***

## Usage Examples

The image below shows an example of the Mode 1 version where the variable *b* is set to the text entered in the selected input element.

<div align="left"><figure><img src="https://3401585094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmnBepgycwgisXr9ya1N4%2Fuploads%2FfdyPNnpaqbJihxoP6t6K%2Fimage.png?alt=media&#x26;token=79345073-20db-4a84-a2ec-47ded9fb8dda" alt="" width="563"><figcaption><p>Example of Get Input Value Mode 1</p></figcaption></figure></div>

In the next example we see a Mode 2 version where the variable *b* is set to the text entered in the selected input element. This time the element is selected using a [CSS Selector](https://developer.mozilla.org/en-US/docs/Learn/CSS/Building_blocks/Selectors).

<div align="left"><figure><img src="https://3401585094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmnBepgycwgisXr9ya1N4%2Fuploads%2FNzjgQOCzTstC6FH2OScf%2Fimage.png?alt=media&#x26;token=b77db14c-f1e9-4e3f-94fd-fdc36e77b617" alt="" width="563"><figcaption><p>Example of Set Input Value Mode 2</p></figcaption></figure></div>

Lastly we have another example with a Mode 2 version. This time the [Show Information Popup](https://docs.zingy.ai/app-editor/page-flow/toolbox-blocks/show-information-popup) block is used to show a message that contains the text entered in the selected element.

<div align="left"><figure><img src="https://3401585094-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FmnBepgycwgisXr9ya1N4%2Fuploads%2FKsZng0CtNdczvW3LHUgW%2Fimage.png?alt=media&#x26;token=a75ad7cb-34fe-4fff-b083-6f78a50de98d" alt=""><figcaption><p>Example of Set Input Value Mode 2</p></figcaption></figure></div>
