Гость
01 Фев 2014 18:00

I added a date field and I am trying to set it to 01/10/1399. I get an "Wrong date input" error.

Please could you fix the date field so we could enter "historical" dates?

I think 1910 is the earliest date we can enter.

Последние изменения: 02 Март 2014


Гость
01 Фев 2014 18:17

This might help you on how to deal with an extended date range: :)

http://stackoverflow.com/questions/2871264/using-strtotime-for-dates-before-1970


Sergey
Total posts: 13,748
03 Фев 2014 00:20

strtotime is used more than 30 times. I cannot change it. This will lead to unstable version of date field. Unfortunately I have to postpone it to Cobalt 9.


Гость
04 Фев 2014 04:11

I was thinking rather of a completely different field. e.g. LongDate that you could even sell separately :) In this way you keep the compatibility and only those who actually need a LongDate would use it...


Sergey
Total posts: 13,748
04 Фев 2014 05:05

Agree. But current field is based on Mootools. And by Joomla 4 or may be even 3.5 who knows we will have to totally get rid of it. So there have to field that will completely replace current field.

So, in other situation I might do what you suggested, but in this situation I will simply need to refactor this field as it is going to be deprecated anyway.


Гость
04 Фев 2014 18:44

If you could pack the date field up as a "LongDate" field and refactor the first occurrence, I'll refactor the rest over the weekend :)

It might be half and year to an year until Cobalt 9 so I would get good use out of it.

PS You may name the field anything else you prefer :)


Sergey
Total posts: 13,748
04 Фев 2014 23:01

have you looked in that field code? I consider this is the most complex field. Not only change strtotime to data_create but also change data selector element. it is not hard for me to create field copy, you can do it yourself by simply coping field folder and changing field class name. That is it.

Then you just looks through all files for strtotime function and change it.

But I am not sure that will solve the problem. There are so many other things involved. But you can try.

Работает на Cobalt