Arc Forumnew | comments | leaders | submitlogin
1 point by nex3 5939 days ago | link | parent

That shouldn't be too hard to hack in, I think... just find some way to capture all /images/* URLs or something and open up a file and send the contents. You might have to be a little careful with MIME types and so forth, but it seems pretty straightforward.


5 points by bogomipz 5939 days ago | link

Just take any URL that is not defop'ed to mean a file name.

Currently, if no op is defined, the server responds with "Unknown operator.". Replace that with the code for opening a file, and if this fails, respond with a proper 404 Not Found message.

-----

3 points by pg 5939 days ago | link

That should work for text/html files.

-----

2 points by bogomipz 5938 days ago | link

By throwing in a hash table which maps from file name extensions to MIME types, it could work for other files as well.

A byte array data type for buffering would do good for performance.

-----