Add sample code for getting values in different forms

Created on 21 November 2023, about 1 year ago

Problem/Motivation

The docs on the element class are really clear and comprehensive!

It would be nice if they also mentioned ways to get the values from the element.

E.g. if you only have a single child element, you can do this:

    $values = array_column($form_state->getValue('multi_value_element'), 'child_element');

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Feature request
Status

Active

Version

1.0

Component

Documentation

Created by

🇬🇧United Kingdom joachim

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024