...composed of an indefinite, perhaps infinite number of hexagonal galleries...

© 1994-2017. David Sklar. All rights reserved.

What function are you?

This story from George via Andrei is simultaneously hilarious and scary.

I’m not sure, if I were a PHP function, which function I’d be. Although figuring that out would be a lot easier if my name were, for example, Max Levenshtein.

Swanky New Ning Sites!

It’s been a lot of hard work, so I’m quite excited that we’ve just released three great new Ning sites: Ning Videos, Ning Photos, and Ning Group.

I particularly like the embeddable slideshow that Ning Photos has, and its companion in Ning Videos, the embeddable player – so you can put photos or videos on your blog or wherever. Both apps let you e-mail in content from your phone, too. Ning Group has some spiffy HTML parsing and file upload features so you can share documents with folks and incorporate music, pics, or anything else in the forums.

Plus, all three sites have the juicy bits that every site on the Ning platform gets – things such as cloneability, complete customization, and built-in REST APIs. I’ve been watching the feeds for clones of photos and videos – I suppose seeing who’s cloned sites you care about is the Web 2.0 version of ego surfing.

More on the Ning Blog and from Kyle.

PHP Cookbook, 2nd Edition

The new edition of PHP Cookbook is on the way! I got one copy yesterday, so it should be making its way into bookstores and online-bookstore-warehouses any day now.

There is lots of new material in this edition – completely revamped XML and OOP sections, new stuff on PDO, Ajax, testing, performance tuning, regular expressions, and lots of other goodies.

Zend Framework, PHP Community on Ning

Some neat Ning + PHP related stuff recently: Ben and Elizabeth set up a Group clone for PHPCommunity –

Ben also set up an app – – where he installed the Zend Framework and made a few tweaks so it’s runnng happily on the Ning Playground. I was pleased to see that our URL mapping support can handle everything that Zend Framework needs.

OSCON 2006 Presentation

The slides from my OSCON 2006 presentation, “I’m 200, You’re 200: Codependency in the Age of the Mashup,” are available at’m-200-You’re-200.pdf.

Heading to OSCON

I’m heading to OSCON today. Things I’m looking forward to (in no particular order): Portland, giving a new talk, seeing friends, learning lots of new things. If you’re at (or going to) OSCON, say hi and tell me how wonderful (or stinky) you think my blog is.

Javascript Toolkits: They're Here to Help

XMLHttpRequest Quirks and PHP has some tips on making HTTP requests from Javascript (and is not really PHP-focused, despite the title). The brief discussion of the benefits and drawbacks of using XML, HTML, or JSON for data exchange is worthwhile, and I suppose there’s nothing wrong with any of the info about the XMLHTTPRequest object, but I think if you’re doing any moderately serious Javascript stuff that requires HTTP requests (see what wonderful contortions I undergo to avoid saying “Ajax”! Oops.), you’ve got problems if you’re interacting with XMLHTTPRequest (or the IE-equivalents via “new ActiveXObject()”) directly.

Instead, use a library such as Dojo or Prototype. There are a lot of subtleties to making requests work properly – things such as cross-browser support and using different request transports based on the kind of data that needs to be sent to the server. If you start down the road of trying to do all that yourself, you’ll go nuts (or at a minimum, waste your time reinventing). If you ignore all of those subtleties, your app won’t work correctly.

So take advantage of the hard work someone else has already done to solve these problems. We may argue over whether real programmers use emacs or vi or Microsoft Visual InterDev 2006 for .NET Enterprise Architect Edition, but there’s not much support for the “I wave a tiny magnet back and forth just-so next to the hard drive” method of editing these days. Avoid waving the tiny magnet to make HTTP requests from Javascript.

PHP5. Wprowadzenie

I just received a copy of PHP5. Wprowadzenie, the Polish translation of Learning PHP 5. I don’t know any Polish, but if my calculations are correct (from Listing 7.13), “Kurczak generała O’Tso” is a spicy dish with chicken, dried pepper pods, maybe some peanuts, green pepper, and other goodies.

David's Big Adventure

I live in New York City, but I’m gearing up for some extended travel. From September 1 to the end of the year, I’ll be in Palo Alto, CA. I’m looking forward to working at Ning HQ for a few months. Then, from the beginning of January 2007 to the end of May, I’ll be in Paris, resuming my working-remotely existence.

I have some packing to do!

XML vs. Control Characters

The XML spec says that in XML documents, “Legal characters are tab, carriage return, line feed, and the legal characters of Unicode and ISO/IEC 10646.” That is:

Char ::= #x9 | #xA | #xD | [#x20-#xD7FF] | [#xE000-#xFFFD] | [#x10000-#x10FFFF]

This means that the control characters under 0x20 (with the exception of the Three Wise Whitespace) are not allowed.

This restriction goes all the way back to the definition of a “character” in the W3C Working Draft of November 14, 1996.

Plenty of brilliance went into crafting that document, so I must be missing something extremely obvious here: why are those control characters outlawed? What is the reasoning behind the spec preventing me from including in an XML document:


Preventing terminal beeps from errant Ctrl-Gs?