I'm
running TW on node.js, so storing
binary files directly in Tiddlers is unproblematic - they just get uploaded and stored as separate files.
However, if I embed e.g. a Powerpoint file, how can I actually access it? I'm looking for a way to include a download link to the file in the text of another Tiddler. But I can't find out how to do that. If I use a normal link to the file's Tiddler, that just opens.
Now according to https://tiddlywiki.com/#How%20to%20embed%20PDF%20and%20other%20documents at least "When you edit the tiddler a link is presented. You can right click on the link in order to download the file. " - but I cannot find that link either. There is just a yellow box saying "This tiddler contains binary data".
Now according to https://tiddlywiki.com/#How%20to%20embed%20PDF%20and%20other%20documents at least "When you edit the tiddler a link is presented. You can right click on the link in order to download the file. " - but I cannot find that link either. There is just a yellow box saying "This tiddler contains binary data".
Not an answer but I did as you did following the canonical url method describe at the official TW site...
then type your url or local path into a tiddler's text body/field (or a custom field to read) ie: file:///C:/Unit%202%20PPT%20Scientific%20Notation-2.ppt
But I don't *have* an URL or local path, that's the problem. The files get uploaded to the server, but in a folder that the node.js server does not make accessible through URLs or in any other way (as far as I can tell).
I'm running TW on node.js, so storing binary files directly in Tiddlers is unproblematic - they just get uploaded and stored as separate files.
However, if I embed e.g. a Powerpoint file, how can I actually access it?
I'm looking for a way to include a download link to the file in the text of another Tiddler. But I can't find out how to do that. If I use a normal link to the file's Tiddler, that just opens.
I see your problem-- I tested with single file : ( Hopefully, someone familiar with node.js will know. Maybe the instructions on the official wiki were for single file TW only. I think I'll stick wirh sigle file if node.js makes access to external files difficult (half my wiki's content is external files)
As you found out, it is problematic, since the tiddlers directory is meant to be used for stuff, that can be used directly by the TiddlyWiki app. A pptx file can _not_ be directly used as a tiddler.
If you want to use 3rd party files and expect the browser to do, what browsers do, you will need to store your ppt files in the files directory as advised in the docs.
The drag and drop IMPORT mechanism can only be used for tiddlers. If you want to serve binary data, it has to go into the files directory.
To download zip files I made a macro (attached) based on what Jeremy suggested. I have not tested it intensively but seemed to work for zip, pdf, png, and gif files.