protected function BaseValidatorForm::getElement in Advanced CSS/JS Aggregation 8.3
Same name and namespace in other branches
- 8.4 advagg_validator/src/Form/BaseValidatorForm.php \Drupal\advagg_validator\Form\BaseValidatorForm::getElement()
- 8.2 advagg_validator/src/Form/BaseValidatorForm.php \Drupal\advagg_validator\Form\BaseValidatorForm::getElement()
Get array element that corresponds to directory.
Parameters
array $array: An associative array to check for the key. Usually a form array.
array $keys_array: An array of keys to check sequentially in a heirachical manner.
Return value
array|bool|mixed The array element or FALSE if not found.
File
- advagg_validator/
src/ Form/ BaseValidatorForm.php, line 365
Class
- BaseValidatorForm
- Base form for all advagg validator options.
Namespace
Drupal\advagg_validator\FormCode
protected function getElement(array $array, array $keys_array) {
foreach ($keys_array as $key) {
if (!isset($key, $array)) {
return FALSE;
}
$array = $array[$key];
}
return $array;
}