Christian,
Thanks for the pointer. I'll see if I can update the docs to more clearly cover this use case.
Cheers,
E. ________________________________ From: Christian Grün christian.gruen@gmail.com Sent: Thursday, July 7, 2022 4:09 AM To: Eliot Kimber eliot.kimber@servicenow.com Cc: basex-talk@mailman.uni-konstanz.de basex-talk@mailman.uni-konstanz.de Subject: Re: [basex-talk] RESTXQ: Serve images that are not within the web app dir
[External Email]
Hi Eliot,
I would like to serve the images from RESTXQ-generated HTML Pages but I’m not sure how to do that other than to use URLs that include the base64 image data directly.
The DBA code contains such an endpoint [1]. Memory consumption will be constant: As file:read-binary is used, the binary data will be streamed directly to the client [2]. The used headers (Cache-Control, Content-Length) are optional and can be arbitrarly adjusted.
Best, Christian
[1] https://urldefense.com/v3/__https://github.com/BaseXdb/basex/blob/da1e55d021... [2] https://urldefense.com/v3/__https://docs.basex.org/wiki/Lazy_Module__;!!N4vo...