--
CFML Conventional Wisdom
http://groups.google.com/group/cfml-conventional-wisdom?hl=en?hl=en
Ok I just noticed that this function actually writes it to a file,
instead of embedding it into the page. But still wouldn't it make
sense to use this and make the output to file optional?
And would that also support writing it to a file? I'm all for a more
generic DataUri().
For example, no need to waste memory with a variable, just read the
file and output to page:
<img src="#toDataUri("./myimage.png")#" />
And it's not limited to just images either:
<script>window.open( '#toDataUri(HtmlCode,"utf-8","Base64")#' )</script>
And if someone decides to start doing data URIs with Base85 (or any
other method) all it requires is a different argument code with
toDataUri and it'll work.