[TYPO3-mvc] Blank Flexform fields overwrite TypoScript values???
Franz Koch
typo3.RemoveForMessage at elements-net.de
Wed Feb 24 14:21:34 CET 2010
Hi,
>> So far, so good. Again I can overwrite the TS settings with my definition in
>> the plugin's flexform. BUT: There's one big downside: Once I've saved the
>> flexform, the TypoScript value is overwritten - no matter if the flexform
>> field is empty or not. Of course, if the according flexform field is empty,
>> the TS setup should NOT be overwritten. But it IS. And therefore no template
>> is found.
>
> Many extension suffers from the problem that flex for fields need a "net set" (ie use default or TS
> value) setting (think NULL), but this isn't possible except for drop downs.
>
> For fields like the template path it's easy to have an empty string take the meaning of "not set",
> but what about numbers? 0 (zero) could be a legal value.
True, but what always works is:
if ($flexFormValue != '') { $settings[$key] = $flexFormValue);
Many extensions work that way, so extbase should also apply this. And
it's in fact easy to implement, all that has to be done is to adopt the
method convertFlexformContentToArray from the
FrontendConfigurationManager to only add fields to the array their value
is not ''.
I'll test it and provide a patch if you guys think that's the way to go.
--
kind regards,
Franz Koch
More information about the TYPO3-project-typo3v4mvc
mailing list