Simon Willison’s Weblog

Subscribe

February 2008

Feb. 3, 2008

Let me be again clear here that Comet isn’t a new single technique. Rather, it’s a combination of existing push technologies with further research into new methods that together provides a robust framework for pushing data to all clients on modern networks.

Michael Carter

# 10:04 pm / michael-carter, comet, javascript

Faster JavaScript Trim. Neat optimisation post—it turns out that while regular expressions are great for removing leading whitespace you can do a lot better at trailing whitespace by manually looping backwards from the end of the string.

# 10:12 pm / whitespace, trim, javascript, optimisation, steven-levithan

Low Pro For jQuery? Dan Webb on why he prefers Prototype over jQuery: “The one big reason was that, while jQuery was super simple and concise when working on smaller projects, it offered no help in structuring larger applications”.

# 10:16 pm / dan-webb, prototype, jquery, javascript, libraries, lowpro

Yahoo! OpenID Provider service now available as a public beta. This actually happened a few days ago, but I’ve been offline for the past week travelling to New Zealand and attending Kiwi Foo.

# 10:17 pm / openid, kiwifoo, beta, yahoo

Interview: Simon Willison on OpenID. Christian Heilmann interviewed me for the YDN blog.

# 10:18 pm / christian-heilmann, interview, openid, ydn, yahoo

Social Graph API. This is freaking awesome. Input one or more URLs to your profile pages and it returns a huge dump of crawled relationship data, based on XFN, FOAF and OpenID links. No API key required and it supports JSON callbacks so you can incorporate it in to a site without even needing to write any extra server-side code.

# 10:34 pm / socialgraph, socialgraphapi, json, jsonp, google

Feb. 8, 2008

Django San Diego. A real-life meeting of Django developers in San Diego, as a direct result of profiles on djangopeople.net. Victory!

# 10:20 am / django, sandiego, django-people, community

LJWorld.com: Kansas Democratic Presidential Caucuses (via) The most beautiful election results page I’ve ever seen. Love the typography and the Google Charts integration.

# 11:17 am / matt-croydon, design, elections, kansas, ljworld, google-charts, typography

querySelector and querySelectorAll. WebKit now supports the W3C Selectors API. Expect the various JavaScript libraries to add this as an optimisation to achieve massive speedups (Prototype are already working on it).

# 11:21 am / prototype, javascript, safari, webkit, w3c, selectors, libraries, queryselector

A proposal: email to URL mapping. Brad’s just too damn smart. A simple solution to mapping an e-mail address to an OpenID that takes advantage of existing technology (YADIS) and doesn’t adversely affect e-mail privacy.

# 11:39 am / email, openid, urls, brad-fitzpatrick, yadis

django-openid—browse. Hooray! Google Code finally has a decent Subversion browser.

# 11:41 am / google-code, subversion

mydeco. Major new Django-powered start-up has launched, based in London.

# 11:43 am / django, mydeco, london, startup

PrinceXML is extremely impressive. I had a poke at Prince (a commercial package for generating high quality PDFs from HTML, XML, CSS and SVG) a few weeks ago and was similarly impressed.

# 12:02 pm / princexml, xml, css, ryan-tomayko, svg

Feb. 10, 2008

themaneater.com Launch. The Maneater’s online edition is where Adrian cut his web development teeth, so it’s great to see them up and running on Django. Important to note that KeepAlive can completely murder Apache/Django performance.

# 8:10 am / apache, django, keepalive, themaneater, adrian-holovaty

Cross-Window Messaging. Now in Firefox 3 trunk, the HTML 5 specified ability for JavaScript to send messages between windows (or iframes) hosted on different domains. Fantastically powerful, but must be implemented with care to avoid accidentally processing bad messages from malicious third parties.

# 12 pm / firefox, firefox3, crosswindowmessaging, javascript, john-resig, html5

Transitioning from Java Classes to JavaScript Prototypes. Peter Michaux shows how JavaScript’s prototypal inheritance can run rings around traditional Java-style classes once you figure out how to take advantage of it.

# 3:10 pm / javascript, prototypalinheritance, java, classes, inheritance, pete-michaux

Event Delegation Made Easy. Dan Webb demonstrates a neat trick for event delegation in jQuery, using CSS selectors and the jQuery .is() method to dispatch to different callbacks from a single event handler based on the target of the event.

# 3:13 pm / eventdelegation, jquery, javascript, dan-webb, delegation

jQuery 1.2 Cheat Sheet. Handy. It helps that most of jQuery’s method names are pretty much self explanatory once you’ve been using the library for a couple of weeks.

# 9:12 pm / jquery, javascript, cheatsheet, gscottolson

Feb. 11, 2008

"Why doesn't jQuery have an XPath CSS Selector implementation?" For now, my answer is: I don't want two selector implementations - it makes the code base significantly harder to maintain, increases the number of possible cross-browser bugs, and drastically increases the filesize of the resulting download.

John Resig

# 5:31 am / jquery, xpath, css, performance, john-resig

Nginx and Memcached, a 400% boost! Ilya Grigorik wrote up my current favourite nginx trick—you set nginx to check memcached for a cache entry matching the current URL on every hit, then invalidate your cache by pushing a new cache record straight in to memcached from your application server.

# 10:05 pm / memcached, nginx, performance, caching, ilyagrigorik

Feb. 13, 2008

Flickr Uploadr: Open Source and Powered by XULRunner. Quietly released a few months ago; it’s really nice.

# 11:30 pm / open-source, javascript, flickr, uploadr, xulrunner, richard-crowley

Feb. 18, 2008

Apache proxy auto-re-loader. Neat trick: set your 502 (Bad Gateway) error document to include a meta refresh tag, automating the refresh needed should a server you are proxying to be temporarily unavailable.

# 9:44 am / apache, proxy, metarefresh, ned-batchelder

queryset-refactor changeset 7126. Malcolm just checked model inheritance in to the queryset-refactor branch, with full documentation and unit tests. People have been requesting this for ages.

# 9:46 am / inheritance, python, django, querysetrefactor

2008 » February

MTWTFSS
    123
45678910
11121314151617
18192021222324
2526272829