Phillip Pearson - Second p0st

tech notes and web hackery from the guy that brought you bzero, python community server, the blogging ecosystem, the new zealand coffee review and the internet topic exchange

2006-4-13

PHP gets built in XML-to-object and XPath functionality

Looking forward to SimpleXML making it out of PHP CVS and into the release version.

It looks like you can't create SimpleXMLElement objects except with the simplexml_from_* methods, though. It would be cool if it were possible to turn a structure into XML... looks like we're meant to use DOMDocument, DomElement etc for that.

Blog archives

Seems that people are talking about using RSS as a blog export format again (I think this Newsforge article kicked it off). Dave Winer did this in November 2002 - then Brent Simmons did a Mac app to view the archives, and I did a Windows one (homepage).

These days, the Movable Type export format is what everyone uses to send their blog data and comments around. It seems that most blogs can generate it,

Danny Ayers pops up in the comments and suggests using RDF instead (surprise!) or perhaps Atom or HTML+microformats.

I like the microformat approach, but I can imagine that it would confuse the hell out of implementers, and if you're trying to replace the MT export format with something more extensible, it's going to have to be dead easy to implement. I'd go for the single-gigantic-feed approach, including comments and trackbacks as well. This is how the MT export format works, and it works fine. Either that, or require everything to be under a URL somewhere on the web, and force importers to download it piece by piece.