[TYPO3-dev] process_datamap() & timestamp
Ernesto Baschny [cron IT]
ernst at cron-it.de
Thu Nov 24 11:04:56 CET 2011
Peter Niederlag schrieb am 23.11.2011 14:38:
> Hello,
>
> Am 23.11.2011 13:58, schrieb Jan Kornblum:
>> Hi Bernd,
> [...]
>> Yes, thats what i've already thought about. But where can this
>> converting take place?
> date and datetime will be processed inside checkValue_input_Eval (and
> stored in UTC?):
>
> case 'date':
> case 'datetime':
> $value = intval($value);
> if ($value > 0 && !$this->dontProcessTransformations) {
> $value -= date('Z', $value);
> }
The opposite is the case:
Input coming from browser is UTC (browser transforms the client-side
input into UTC via JavaScript), which is transformed to server timezone
and stored into the DB with server TZ.
This transformation needs to be disabled if you are just reading the
data from database and re-writing it back (no client involved):
$tce = t3lib_div::makeInstance('t3lib_TCEmain');
$tce->stripslashes_values = 0;
$tce->debug = 0;
> $tce->dontProcessTransformations = 1;
$tce->start(array(),$cmdmapArray);
$tce->process_cmdmap();
"transformations" in this situation are stuff that TCEmain does on the
input that usually comes from the browser (I think *only* RTE and
datetime in UTC) and which cannot be reapplied at will (not idempotent).
These are disabled on copy / translation / and other internal methods
and should probably also be disabled in the situation from Jan.
Cheers,
Ernesto
More information about the TYPO3-dev
mailing list