Hi Eric, I was interested in this script and I already asked one question after I attempted to tweak it for another purpose (about whether there's a way to identify tiddlers where custom fields, and nothing else, have been modified - http://tinyurl.com/nlj3aj). But now I realize I don't understand something about the script exactly as it's written: If I give a tiddler a single word title (and the tag "journal"), the tiddler will be listed by this script, but the tiddler title is not a link. Why is that? thanks! cmari
On Sep 17, 5:33 pm, Eric Shulman <elsdes...@gmail.com> wrote: > > I have tried a DefaultTiddlersTweak with > > "config.shadowTiddlers.DefaultTiddlers=new Date().formatString("0DD- > > MMM-YYYY");" in the tiddler, which is the only one that seems to > > actually work, but it only brings up the most recent tiddler, not all > > tiddlers for the day. > > You can use the 'recent:N' TW core paramifier to view the most > recently modified tiddlers upon startup. For example: > http://www.TiddlyTools.com/#recent:5 > will show the 5 most recently modified tiddlers, bypassing the > DefaultTiddlers definition (if any). > > However, this built-in syntax will always display the specified # of > tiddlers, even if you have changed more or less than that number in > the past day, and will display tiddlers other than journals. > > To get precisely what you asked for (*journal* tiddlers created/ > modified in the past 24 hours), you can try this tweak instead: > -------------------------------- > var titles=[]; > var now=new Date().getTime(); > var tids=store.getTiddlers('modified','excludeLists').reverse(); > for (var i=0; i<tids.length && now-tids[i].modified.getTime() > <86400000; i++) { > if (tids[i].isTagged('journal')) > titles.push(String.encodeTiddlyLink(tids[i].title));} > > config.shadowTiddlers['DefaultTiddlers']=titles.join('\n'); > -------------------------------- > > Place the above code into a tiddler tagged with 'systemConfig'. Then > save-and-reload the document. Upon startup, the code will be invoked > so that all tiddlers modified in the prior 24 hours are automatically > identified, and their titles stored as a whitespace-separated, > bracketed list in the shadow definition of DefaultTiddlers and then > displayed as the initial tiddlers for that session. > > enjoy, > -e > Eric Shulman > TiddlyTools / ELS Design Studios --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To post to this group, send email to tiddlywiki@googlegroups.com To unsubscribe from this group, send email to tiddlywiki+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/tiddlywiki?hl=en -~----------~----~----~----~------~----~------~--~---