[TYPO3-core] RFC: Bug #4515: Date fields displayed wrong in TCEforms

Martin Kutschker Martin.Kutschker at n0spam-blackbox.net
Wed Nov 15 10:25:26 CET 2006


Dmitry Dulepov schrieb:
> Hi!
> 
> Ernesto Baschny [cron IT] wrote:
> 
>> I just don't agree with that part:
>> -                                               $value =
>> date($option,$itemValue);
>> +                                               $value =
>> date('d-m-Y',$itemValue);
>>
>> Why are you not using $option anymore? I don't know where this
>> $config['format.']['option'] comes from, is it documented somewhere? Can
>> this be set through TCA? How?
> 
> By the way, typo3 has a configuration setting for date format. That one 
> should be used (for consistency).

Yes, but a) that's not the code for "eval"/"readOnly" but "none"/"format" 
(see my other post) and b) it's currently stated in the TCA docs that the 
format is d-m-Y.

Of course it would make sense to use the date setting but then it should be 
improved and the TCA restriced. So instead of allwing date/strftime formats 
in the TCA we would use generic terms like date, shortdate, longdate, time, 
  longtime, etc to describe the output. This would give the site admin the 
power to choose the date/time format of his locale.

So I propose to remove the complex date formats form "none"/"format" in 
4.0.3. They were not documented, so they don't exist ;-) Instead of 'd-m-Y' 
it should use the config for dates.

In 4.1 we deprecate the time formats for eval and use also the config for 
dates. The date and time settings are improved to cover the types mentioned 
above.

See also my posting "time/date display in FE (and BE)" on 24.8.06

Masi



More information about the TYPO3-team-core mailing list