Lately I've been starting to play with dynamic web pages again, after a long break. I've converted to RESTology mainly due to what I've learned at work coupled with an interest in Python's WSGI interface.
In that vein I've written two experimental scripts that manage bookmarks and an feedreader, dogears and fads. Neither script is really suitable for publication at this point yet. Fads is totally read-only at this point, the feed cache must be refreshed with an external script. I actually plan on leaving it that way but do want some tracking of what entries have been read, possibly even tagging.
But back on the subject of REST, I'm really enthusiastic about how it encourages thinking about the structure of objects in a web application. That's on top the ease of writing client scripts. However, I did find one issue when working with my test applications. Konqueror does not support PUT and DELETE requests! When using XMLHttpRequest objects, Konqueror limits you to GET and POST. Based on the code it looks like an over-restrictive security mechanism. I took the lazy way out and created handlers that accept POST requests with an "op" param, the op is either PUT or DELETE. So posting to the URL with that parameter set makes a phony PUT or DELETE request.
Anyway, aside from the vagaries of browser support, I'm finding that REST and WSGI make writing web-apps fun again.
© Copyright 2009-2011 John Mulligan
Every blog page or article on this site is available under the CC-BY-SA license unless otherwise noted.