> I get "errors" when I put the macro in the DefaultTiddlers (but still
> imports correctly);
You can't put TW macros directly into the DefaultTiddlers. That
tiddler can only contain a white-space separated list of tiddler
titles and/or tag filter syntax, e.g.:
SomeTiddler SomeOtherTiddler [tag[startup]] AnotherTiddler
will automatically open 3 named tiddlers plus any tiddlers tagged with
'startup'
As you've already noted, to invoke a macro during startup you need to
put it into a tiddler whose content is rendered whenever the document
is opened. For example, you could put <<loadTiddlers>> into your
MainMenu or even the SiteTitle tiddler, since those tiddlers are
always rendered at startup time.
Another approach is to add the following line to your PageTemplate
<span macro="tiddler SiteStartup" style="display:none"></span>
and then create a tiddler called SiteStartup in which you invoke
<<loadTiddlers>>. The span in the PageTemplate is hidden
("display:none"), so that no unwanted output is displayed. (Note:
<<loadTiddlers>> doesn't actually produce any inline output, but other
macros that can be invoked in this way might, so this just makes sure
that nothing unintended is shown.)
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.