$data['page'] or $data['page.'] ?
Closed this issue · 2 comments
TimothyAlexisVass commented
will be converted to the following PHP array:
$data['page'] = 'PAGE';
Upon evaluation, a “PAGE” object will be created first, and the parameter $data['page.'] will be assigned to it.
Which is it, page
or page.
?
mbrodala commented
Technically both. The following TypoScript:
page = PAGE
page {
test = 1
}
Will become:
$data = [
'page' => 'PAGE',
'page.' => [
'test' => 1,
],
];
So the version with trailing dot is used for nested options, the one without for assignments. Otherwise one or the other information would be lost.
mbrodala commented
I just proposed a unflattened version of the PHP array which should make this clearer.