On Saturday, February 22, 2014 7:18:01 PM UTC-8, Anton Aylward wrote: > > In the ChapterViewTemplate > <b>Date: </b><span macro='view dateline date'></span> > But in the ChapterEditTemplate I have a problem. > <b>Date: </b><span macro='edit dateline '></span> > I just get this field with a big number. > Its not a date. >
I tried the following: 1) goto http://classic.tiddlywiki.com 2) open More>Shadowed tab 3) open EditTemplate shadow 4) edit EditTemplate 5) added: <div class='editor' macro='edit dateline'></div> 6) open ViewTemplate shadow 7) edit ViewTemplate 8) added: <div macro='view dateline date'></div> 9) create NewTiddler 10) edit NewTiddler 11) edit "1962-07-24" into dateline input field 12) press "done" 13) dateline output is displayed as: "23 July 1962" 14) edit NewTiddler again 15) dateline input field still shows "1962-07-24" * I'm not seeing a "big number" as you reported * The date conversion is "off by 1" ... which is a common JS problem (day and month numbers are 0-based, e.g, 0-30 for days, and 0-11 for months) Still... this doesn't really give you what you want... which is THREE inputs in edit mode that are converted to a single datetime value for storage and display, and then split again into three values when editing. Another possibility would be to figure out a way (via custom javascript) to force the input field to have type="date" (a new HTML5-supported input type). This would provide a fully interactive popup calendar for selecting the desired date. I experimented with *manually* changing the DOM element field type to "date" (by using the browser-based debugger to inspect the element and then modify the type="..." attribute by hand)... and it worked nicely. I'll look into how to automate that, so that you can specify a date input field without a lot of hackery. enjoy, -e Eric Shulman TiddlyTools / ELS Design Studios YOUR DONATIONS ARE VERY IMPORTANT! HELP ME TO HELP YOU - MAKE A CONTRIBUTION TO MY "TIP JAR"... http://TiddlyTools.github.com/fundraising.html#MakeADonation Professional TiddlyWiki Consulting Services... Analysis, Design, and Custom Solutions: http://www.TiddlyTools.com/#Contact -- 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 post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/tiddlywiki. For more options, visit https://groups.google.com/groups/opt_out.

