On Jun 3, 12:07 pm, mdipierro <[email protected]> wrote: > Vasile approach (create an action to serve the blob as an image) is to > be preferred because Yarko's approach is not cross-browser compatible.
.... just to be clear: this approach does not by itself serve a blob - if there is no image file in the "/uploads" folder which matches the saved image filename, the "blob" is not served (actually - in this way, there is no blob saved --- just the uploaded filename). IF you either [a] save image as a blob, or [b] generate an image, to use Vasilie / Massimo approach, you will need to ensure 2 things: [1] - that you somehow point to path/filename where the image will exist as a file [2] - that, during the request, the image (blob) is written out to that file, before serving the request. And, yes - serving an image from a "file" will work with old / "all" browsers (at least those that render images). - Yarko > > Anyway, if you choose to do it the Yarko's way be careful because you > need to base64 encode not urlescape. web2py provides a helper to do > this > > http://web2py.com/examples/static/epydoc/web2py.gluon.html-module.htm... > > On Jun 3, 11:52 am, Vasile Ermicioi <[email protected]> wrote: > > > > > Yarkos approach will work only if you store it in a blob field, but not if > > image is uploaded in a directory > > my approach (Massimos approach :) ) should work for both cases

