Memochipan
Memochipan

Reputation: 3465

Enable TYPO3 page content expiration date

I'm in TYPO3 v.6.2 and from this year the expiration date is no longer accepting dates beyond 2020-12-31.

That was some sort of prophecy? XD

enter image description here

I suppose it is just a matter of configuration.

Where can I change that to enable future expiration dates?

Upvotes: 0

Views: 430

Answers (1)

Peter Kraume
Peter Kraume

Reputation: 3747

That's the gentle reminder to upgrade your TYPO3 installation ;)

Your problem is that in old TYPO3 versions the upper limit of the date selector is hard coded in the TYPO3 core.

This can be fixed with a little bit of PHP code, e.g. in the ext_localconf.php or Configuration/TCA/Overrides/YOUR_TABLE_NAME.php of your own extension:

$GLOBALS['TCA']['YOUR_TABLE_NAME']['columns']['YOUR_FIELD_NAME']['config']['range']['upper'] =
    mktime(0,0,0,12, 31, 2030);

The code snippet must be adapted for every table and field that contains a date selector.

Upvotes: 2

Related Questions