# Image upload

Upload field renders an Add media button. Clicking it opens the standard Select or Upload Media dialogue and will render the `thumbnail` size of the selected image. Clicking the Trash button resets the field.

## Example configuration

```php
...
array(
    'title' => 'My upload field title',
    'id' => 'upload-option',
    'desc' => 'Short description for the field',
    'tab' => 'main',
    'type' => 'upload',
),
...
```

This will produce the following

![](/files/-LKMTm9b26FnqdQ27Pvn)

## Params

| Name    | Type   | Description                                                      |
| ------- | ------ | ---------------------------------------------------------------- |
| `type`  | string | `upload` **(required)**                                          |
| `id`    | string | Unique ID that will be used to retrieve the value **(required)** |
| `tab`   | string | Specifies in which tab this option will be rendered              |
| `title` | string | Shows a heading to the left of the field                         |
| `desc`  | string | Shows a description text (can have HTML)                         |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.alchemy-options.com/fields/upload.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
