Simon Willison’s Weblog

Subscribe

Saturday, 19th July 2008

php: rfc: closures (via) I never thought I’d see the day, but a patch adding closures to PHP has been both proposed and accepted! Looks like a solid implementation—the syntax is similar to JavaScript but makes explicit which variables are to be captured. As with much of PHP, values are copied in to the closure by default but you can use an ampersand to specify JavaScript-style pass-by-reference instead.

# 10:58 pm / closures, functional-programming, javascript, php

Simple Top-Down Parsing in Python. Eye-opening tutorial on building a recursive descent parser for Python, in Python that uses top-down operator precedence.

# 11:37 pm / compilers, effbot, fredrik-lundh, parsing, python, recursivedescent

The Truth about Web Navigation. Jeremy Zawodny on regular users understanding the browser address bar: “They don’t. And they never will.” Then they’re going to get phished, and there’s absolutely nothing we can do to help them.

# 11:42 pm / depressing, jeremy-zawodny, navigation, phishing, security, usability

HeatMapAPI (via) Cool (or should that be hot?) API for adding heat maps to any Google Maps application.

# 11:46 pm / google-maps, heatmaps, mapping

We’re added some iCal views to BBC Programmes. BBC /programmes is one of the most exciting public facing parts of the BBC’s online offerings.

# 11:48 pm / bbc, duncanrobertson, ical, slashprogrammes

Jinja2 Final aka Jinjavitus Released. The Jinja template engine now has auto-escaping as an optional feature, disabled by default. Worth considering as an almost drop-in replacement for Django’s template language if features such as macros and compilation to Python code appeal to you.

# 11:52 pm / autoescaping, django, jinja, python

2008 » July

MTWTFSS
 123456
78910111213
14151617181920
21222324252627
28293031