function FormFieldRegistry::walk
Transforms a PHP array in a list of fully qualified name / value.
1 call to FormFieldRegistry::walk()
- FormFieldRegistry::all in vendor/
symfony/ dom-crawler/ FormFieldRegistry.php - Returns the list of field with their value.
File
-
vendor/
symfony/ dom-crawler/ FormFieldRegistry.php, line 136
Class
- FormFieldRegistry
- This is an internal class that must not be used directly.
Namespace
Symfony\Component\DomCrawlerCode
private function walk(array $array, ?string $base = '', array &$output = []) : array {
foreach ($array as $k => $v) {
$path = $base ? \sprintf('%s[%s]', $base, $k) : $k;
if (\is_array($v)) {
$this->walk($v, $path, $output);
}
else {
$output[$path] = $v;
}
}
return $output;
}