Hi Jeremy,

thanks for the change in boot.js. I have a question though:

Wouldn't it be possible to handle all unkown MIME types as binary data ?
That would ensure that people could for example embed word or excel files or a bunch of other file types (at the expense of some txt/ascii based formats). I am not sure if that is a good idea, or if that is possible to implement since most other systems seem to access contentTypeInfo as hashmap.

/Andreas

Am 23.02.2015 um 11:58 schrieb Jeremy Ruston:
Hi Stephan

Just to be clear, TW5 does indeed support binary tiddlers (images being a good example). You can drag a ZIP file into TW and the right thing happens. The limitation at the moment is that there's no built-in way to download the file afterwards. You can use something like the following code to create a download link for a binary tiddler:

\define download-inner(title)
<a href=<<makedatauri """$(text)$""" """$(type)$""">> download="download">Download "$title$"</a>
\end

\define download(title)
<$set name="type" value={{$title$!!type}}>
<$set name="text" value={{$title$!!text}}>
<<download-inner "$title$">>
</$set>
</$set>
\end

<<download "Motovun Jack.pdf.zip">>

However, the .ZIP file extension needs to be registered in boot.js before this will work:

$tw.utils.registerFileType("application/zip","base64",".zip");

I've commited ZIP support here:

https://github.com/Jermolene/TiddlyWiki5/commit/a2493f80a973b24ad3d3affda945c437b98c2d2e

Best wishes

Jeremy.






On Mon, Feb 23, 2015 at 9:35 AM, Stephan Hradek <stephan.hra...@gmail.com <mailto:stephan.hra...@gmail.com>> wrote:



    Am Montag, 23. Februar 2015 10:06:00 UTC+1 schrieb Andreas Hahn:

        Yes, it is unfortunately it is the only way to do it, without
        editing core source code.

        I btw use powershell with a function I found online[1], that
        makes it kinda easy to do (since it even copies it to the
        clipboard).


    I think I have something similar for jEdit.
-- 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+unsubscr...@googlegroups.com
    <mailto:tiddlywiki+unsubscr...@googlegroups.com>.
    To post to this group, send email to tiddlywiki@googlegroups.com
    <mailto:tiddlywiki@googlegroups.com>.
    Visit this group at http://groups.google.com/group/tiddlywiki.
    For more options, visit https://groups.google.com/d/optout.




--
Jeremy Ruston
mailto:jeremy.rus...@gmail.com <mailto:jeremy.rus...@gmail.com>
--
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+unsubscr...@googlegroups.com <mailto:tiddlywiki+unsubscr...@googlegroups.com>. To post to this group, send email to tiddlywiki@googlegroups.com <mailto:tiddlywiki@googlegroups.com>.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.

--
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+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/d/optout.

Reply via email to