Don’t call me DOM

28 April 2005

WordPress and Named Entities

Filed under:

As I mentioned a few days ago, my blogging tool, WordPress 1.5, doesn’t deal with named entities as it should. Namely, when fed with named entities, it outputs them as is in any context. But if named entities are fine in (X)HTML, they’re not with the various other flavors of RSS/RDF, where these entities cannot be parsed.

It didn’t take much time to see that other people had the same problem as I had; fortunately, it didn’t take much time either to learn how to do a plugin for WordPress.

12 July 2004

Testing CGI scripts with QUERY_STRING, in PHP

Filed under:

When developing a CGI script and before putting on the production server, you need to test it; to catch runtime errors, but more generally, to check if you get the expected result depending on the parameters.

To emulate a GET request without setting up a Web server, the easiest method is probably to set the QUERY_STRING and REQUEST_METHOD environment variables and run the script through its interpreter, e.g. REQUEST_METHOD="GET" QUERY_STRING="foo=bar" php4 filename.php.

Well, this used to work till recently – I assumed it broke with PHP 4.3 release; nowadays, the php4 executable comes in two flavours: the CLI and the CGI SAPI; the former is designed to be use out of Web context, so isn’t much relevant to this case.

« Newer entries

Picture of Dominique Hazael-MassieuxDominique Hazaël-Massieux ( is part of the World Wide Web Consortium (W3C) Staff; his interests cover a number of Web technologies, as well as the usage of open source software in a distributed work environment.