[TYPO3-core] RFC #9282: Allow subkeys for TypoScript "config." array

Martin Kutschker masi-no at spam-typo3.org
Sun Sep 7 19:12:18 CEST 2008


Dmitry Dulepov [typo3] schrieb:
> Hi!
> 
> Benjamin Mack wrote:
>> Problem:
>> As this issue came up in the recent discussion about the simulate
>> static typo3, I wrote the supersimple patch for it.
>>
>> The config. parts in TypoScript from the page-specific config. (e.g.
>> page.config...) and the generic config part are merged together when a
>> page is generated.
>>
>> However, it is not possible to have subkeys in there:
>> config.myoption = 1
>> config.myoption.param1 = foo
>> page.config.myoption.param2 = bar
>>
>> In the core right now, param1 will be removed when it is merged and so
>> it's unaccessible. This is because the merge is not done in a
>> recursive way.
>>
>> Solution:
>> The attached patch fixes this issue and allows the above examples.
> 
> I thought why it was not possible before but I could not find any
> reason. So +1 to the patch. Please, commit it! Very nice thing to have!

I don't know why there was only a simple array merge and not a recursive
 one. I think it was to save CPU cycles which if the assumption is true
is probably "tuning" at the wrong point.

So +1.

Masi


More information about the TYPO3-team-core mailing list