You are here

public static function WebformMultiple::getStorageKey in Webform 8.5

Same name and namespace in other branches
  1. 6.x src/Element/WebformMultiple.php \Drupal\webform\Element\WebformMultiple::getStorageKey()

Get unique key used to store the number of items for an element.

Parameters

array $element: An element.

string $name: The storage key's name.

Return value

string A unique key used to store the number of items for an element.

5 calls to WebformMultiple::getStorageKey()
WebformMultiple::addItemsSubmit in src/Element/WebformMultiple.php
Webform submission handler for adding more items.
WebformMultiple::addItemSubmit in src/Element/WebformMultiple.php
Webform submission handler for adding an item.
WebformMultiple::processWebformMultiple in src/Element/WebformMultiple.php
Process items and build multiple elements widget.
WebformMultiple::removeItemSubmit in src/Element/WebformMultiple.php
Webform submission handler for removing an item.
WebformMultiple::validateWebformMultiple in src/Element/WebformMultiple.php
Validates webform multiple element.

File

src/Element/WebformMultiple.php, line 965

Class

WebformMultiple
Provides a webform element to assist in creation of multiple elements.

Namespace

Drupal\webform\Element

Code

public static function getStorageKey(array $element, $name) {
  return 'webform_multiple__' . $element['#name'] . '__' . $name;
}