Just to add that the date format for "1994-11-05T13:15:30Z" is called ISO-8601:

https://en.wikipedia.org/wiki/ISO_8601

The reason that TW uses the 20191031080056713 format is that it is easier to 
use for computations and comparisons.

Best wishes

Jeremy

--
Jeremy Ruston
[email protected]
https://jermolene.com

>> On 1 Nov 2019, at 00:10, TonyM <[email protected]> wrote:
> 
> Why ?,
> 
> The type setting in edit-text sets the html type values and is not aware of 
> tiddlywiki date formats. You can use them but you will need to work to use 
> this format dates because you can't simply use javascript as you would on a 
> typical html page.
> 
> The format used by tiddlywiki is more precise and numeric only. As a result 
> you can test if one is greater than the other to compare which was 
> first/last. The other date formats need further formatting to do any such 
> comparisons. Look for the date picker plugin to select dates in tiddlywiki 
> format. You can use the html format but you will need to translate it to 
> something similar to do any processing on the dates. You can also make a date 
> stamp button for now using the Now macro.
> 
> Using the view widget, format date and Now macro you can make tiddlywiki 
> dates look like html dates.
> 
> Regards
> Tony
> 
> 
>> On Thursday, October 31, 2019 at 7:05:24 PM UTC+11, Sebastian Ovide wrote:
>> Hi Tony
>> 
>> thanks for that.
>> 
>> I get the concept. My question was about the format that TW is using in the 
>> tiddlers. 
>> 
>> example. 
>> 
>> <$edit-text field="my_date" type="date"/>
>> <$edit-text field="my_datetime" type="datetime-local"/>
>> 
>> will create these fields:
>> created: 20191030080335371
>> modified: 20191031080056713
>> my_date: 2019-10-02
>> my_datetime: 2019-10-03T11:01
>> title: AAAAAA
>> using the the format by the browser using UTC (so your logic applies). 
>> 
>> so my specific question is about the reasoning behind choosing that format 
>> rather than the standard UTC ?
>> 
>> Just curious.
>> 
>> Regards
>> 
>>> On Thursday, 31 October 2019 01:19:58 UTC, TonyM wrote:
>>> Sebastian
>>> 
>>> UTC does not refer to the format as you seem to believe, it refers to the 
>>> dates time zone. UTC is the universal time held in Greenwich.
>>> 
>>> It's easy to be confused with this but the trick is to store the date time 
>>> in UTC but when that time is displayed is converts to local time, using 
>>> your browser locality settings and time zone. This allows your wiki to 
>>> respond to local daylight savings, or when you work in another time zone, 
>>> or you import tiddlers from another time zone.
>>> 
>>> See https://tiddlywiki.com/prerelease/#Date%20Fields
>>> 
>>> Once you grasp that, return with any more detailed questions.
>>> 
>>> Regards
>>> Tony
>>> 
>>>> On Thursday, 31 October 2019 04:24:54 UTC+11, Sebastian Ovide wrote:
>>>> Hello all
>>>> 
>>>> TiddlyWiky stores dates in a format referred as UTC. Example: 
>>>> 20191030170157357. But the UTC is very common to see everywhere looks like 
>>>> 1994-11-05T13:15:30Z 
>>>> 
>>>> any idea on the reason of choosing that format ?
>>>> 
>>>> thanks
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "TiddlyWiki" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/tiddlywiki/67434630-ed18-4dd2-88be-b038b2b59494%40googlegroups.com.

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/21EDEB8A-981A-488C-ADCF-C50EE6D73BA5%40gmail.com.

Reply via email to