On further examination I have decided that websockets are overkill for my purpose, it seems that XHR v2 is a better fit for file uploads.
Here is an example: https://github.com/Integralist/XHR2-Multiple-File-Upload--with-PHP- That code makes me believe that I will be able to accomplish a progressbar without having to change my current PL web server code at all. To be continued after I actually try it... On Mon, May 28, 2012 at 1:41 PM, Henrik Sarvell <hsarv...@gmail.com> wrote: > Thanks Jose, awesome! > > Will check this out more thoroughly tonight. > > What do you mean with "xor descrambling", the ut8 decode function? It > has a comment labelling it as slow. > > > > > On Mon, May 28, 2012 at 12:54 AM, José Romero <j...@2.71828.com.ar> wrote: >> On Sun, 27 May 2012 18:53:31 +0700 >> Henrik Sarvell <hsarv...@gmail.com> wrote: >> >>> Google couldn't show me any prior discussions of websockets and >>> picolisp. >>> >>> Is it too early to start thinking about this maybe, seems like the >>> spec/ref is still changing a little bit too fast/much atm? >>> >>> http://en.wikipedia.org/wiki/WebSocket >>> >>> http://tools.ietf.org/html/rfc6455 >>> >>> C lib: http://git.warmcat.com/cgi-bin/cgit/libwebsockets/ >>> >>> It came up today when I started to think about how crude file uploads >>> via http is with no way of knowing the progress, but they can be used >>> for much much more than fancy uploading interfaces of course. >>> >>> Having looked a bit at the ref ( http://tools.ietf.org/html/rfc6455 ) >>> it seems to me that it looks quite straight forward. >>> >>> The question is, what is easier/more efficient, implementing this from >>> scratch or with the help of the C lib and native? That is the question >>> that maybe someone more experienced in C/in general than me can >>> answer? >> >> I guess i should have posted this here before: >> https://bitbucket.org/cyborgar/web.l/src/249fe9f5c7d8/web/sockets.l >> >> That implements the RFC almost completely (there's no much >> implementation of the error code thingamajig because actually browsers >> don't even implement ping/pong correctly yet!). The implementation is >> in pure lisp, but it could be accelerated with a C library (actually >> the only thing to accelerate is the xor descrambling, could be done in >> an 'in-like environment). The webtest.l in the root of the repo provides >> a (ugly) chat server example using my web.l framework. Sorry if the code >> is not very elegant but I didn't devote that much time to that example. >> >> Here's the documentation of that module: >> https://bitbucket.org/cyborgar/web.l/wiki/Sockets >> >> Also, the spec is pretty much set in stone, at least as far as the IETF >> is concerned, RFC 6455 is a standards track document. >> >> Cheers, >> José >> -- >> UNSUBSCRIBE: mailto:firstname.lastname@example.org?subjectUnsubscribe -- UNSUBSCRIBE: mailto:email@example.com?subject=Unsubscribe