diff --git a/core/version_api.php b/core/version_api.php index 14b521d..036fa18 100644 --- a/core/version_api.php +++ b/core/version_api.php @@ -111,13 +111,14 @@ class VersionData { if( $p_value == '' ) { $t_value = date_get_null(); } else { - $t_value = strtotime( $p_value ); - if( $t_value === false ) { + $t_date = date_create_from_format( config_get( 'normal_date_format' ), $p_value ); + if( $t_date === false ) { throw new ClientException( "Invalid date format '$p_value'", ERROR_INVALID_DATE_FORMAT, array( $p_value ) ); } + $t_value = $t_date->getTimestamp(); } } }