Issue Bug Closed

#63945Date-Validation in forms fails on Windows systems due to missing strptime()

Stephan Großberndt 12/17/14, 01:11 updated 10/02/18, 11:48

Description

The function strptime() is not implemented on Windows platforms: http://php.net/manual/en/function.strptime.php

It is used in TYPO3\CMS\Form\Validation\DateValidator to validate a given date against a configurable formatting string.

There are several formatting strings available on Linux (depending on the C library): http://php.net/manual/en/function.strftime.php
In Windows there are fewer available: http://msdn.microsoft.com/en-us/library/fe06s4ak.aspx

In order to overcome this limitation there could either be a sysext/core/Classes/Utility/DateUtility.php strptime()-calls or a changed validation routine in TYPO3\CMS\Form\Validation\DateValidator::isValid() which does not use strptime() anymore.

Reviews 2