The first one works perfectly. (There is a syntax error in the second, which I haven't found yet.)
Thank you very much! On Feb 11, 9:48 pm, Eric Shulman <[email protected]> wrote: > for the InlineJavscript use-case: > > <script> > var plugins=... > var out=plugins.map(function(t) { > var temp=store.getTiddlerSlice(t.title,'Conjunction')+' ' > +store.getTiddlerSlice(t.title,'Subclause')+' ' > +store.getTiddlerSlice(t.title,'Mainclause'); > return temp.substr(0,1).toUpperCase()+temp.substr(1); > }).join('\n'); > return out; > </script> > > The <<forEachTiddler>> use-case is different, because the "write" > clause isn't a function, it's just an expressions to be evaluated. > Thus, it doesn't have a 'return' statement. Fortunately, you *can* > put more than one javascript statement into the "write" clause... the > value of the clause is the value of the last statement. Something > like this should work (untested): > > <<forEachTiddler > where > 'tiddler.tags.contains("subconj")' > write > 'var temp="<<tiddler [["+tiddler.title+"::Conjunction]]\>\> > <<tiddler [["+tiddler.title+"::Subclause]]\>\>, <<tiddler > [["+tiddler.title +"::Mainclause]]\>\>. \n"; > temp.substr(0,1).toUpperCase()+temp.substr(1);' > > enjoy, > -e -- You received this message because you are subscribed to the Google Groups "TiddlyWiki" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/tiddlywiki?hl=en.

