How do you use "$:/core/templates/canonical-uri-external-image" ?

127 views
Skip to first unread message

Mark S.

unread,
Jul 31, 2015, 8:18:49 PM7/31/15
to TiddlyWiki
I've tried using "$:/core/templates/canonical-uri-external-image" as a template on image tiddlers, the idea being to assign a new base url. But when you apply the template to an image transclusion, you don't get back an image. Does this template do anything, and if so, how?

Thanks!
Mark

Jeremy Ruston

unread,
Aug 8, 2015, 8:35:00 AM8/8/15
to TiddlyWiki
Hi Mark

That template is specifically used during the saving of external images under Node.js. It isn't intended to be used for anything else.

What are you trying to achieve?

Best wishes

Jeremy.


--
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 tiddlywiki+...@googlegroups.com.
To post to this group, send email to tiddl...@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/d951eb8f-82dc-4066-bf2a-d75fd21d032a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Jeremy Ruston
mailto:jeremy...@gmail.com

Mark S.

unread,
Aug 8, 2015, 3:18:32 PM8/8/15
to TiddlyWiki, jeremy...@gmail.com

I was imagining that as you move a TW between node.js, or between various platforms, you can have a template that you would apply to all your image links. By changing the template, you could change where the images point to. This is useful because the pathing is different between different platforms.

I can accomplish all this by making all image links by a global macro, but this isn't standard. I thought if all links could be formatted with a pathing template then that would provide a long-term, standard solution.

Thanks!
Mark

Jeremy Ruston

unread,
Aug 9, 2015, 9:47:29 AM8/9/15
to TiddlyWiki
Hi Mark

I was imagining that as you move a TW between node.js, or between various platforms, you can have a template that you would apply to all your image links. By changing the template, you could change where the images point to. This is useful because the pathing is different between different platforms.

I can accomplish all this by making all image links by a global macro, but this isn't standard. I thought if all links could be formatted with a pathing template then that would provide a long-term, standard solution.

That's pretty close to what this template is for, at or least a part of it: it is used under Node.js to specify the path for external tiddlers to reference their content.

The external tiddler mechanism pretty much addresses your goals, at the cost of making each of the images your working with into a tiddler.

If you need something slightly different that I would recommend using custom global macros to encapsulate your image references.

Best wishes

Jeremy

 

For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages