Archive > July 2006

My name is not really Andrei

31 July 2006 » In PHP » 8 Comments

Ryan Kennedy commented on the presentation I gave at OSCON; specifically, about the transliteration support in PHP 6. I wanted to follow up and explain exactly what it is and, unfortunately, what it is not.
Ryan was excited about the possibilities presented by transliteration, especially as it applies to representing foreign names in reader’s native script (think mail readers). This works really well for Japanese names:

echo str_transliterate("やまもと, のぼる", "Any", "Latin");

And the result is:

  yamamoto, noboru

This is sweet, right? We get an approximate spelling of the foreign name and one could even attempt to pronounce it. But does it work for all script pairs?

echo str_transliterate("Tom Cruise", "Latin", "Cyrillic");

What do we get for this paragon of fame?

  Том Цруисе

Hmm. If I had to reconstruct for you English speakers what that sounds like in Russian, it would be something close to TOM TSRU-EE-SEH. Probably not how he’d like to be known in Russia. What is the problem here?
Continue reading “My name is not really Andrei” »

Back from OSCON 2006

29 July 2006 » In Books, PHP, Talks » 3 Comments

Just got back from OSCON which was again in Portland this year. The conference was excellent, as always and so were the events and extracurricular activities. The sheer variety of talks at OSCON is exciting and frustrating at the same time: exciting because I attended several talks that I would not get to hear at a more focused conference, and frustrating because of the time conflicts between these talks.
The slides from my own session on PHP 6 and Unicode are online now.
By the way, if you like books just a tiny little bit and happen to be in Portland, do yourself a favor: set aside a full day and visit the Powell’s. It the world’s largest independent used and new bookstore (covering, oh, a couple of city blocks) and has an amazing collection of books (including some very rare ones). You could literally lose your friends and family there and wonder among the stacks for hours whilst salivating giddily over the titles on whatever topic your mind can imagine. And don’t worry, there is always the coffee shop to come back to and get provisions to sustain yourself.

Photos from Moscow

22 July 2006 » In Photography, Travel » 2 Comments

The photos from the Moscow part of my trip to Russia are now up on the site. It’s taken longer than I expected to process them. This is partly because it was the first time I shot everything in RAW format in order to be able to adjust exposure and white balance easier. An unintended consequence of this decision was that I spent way more time on each photo than I usually do, tweaking things to be just perfect, and doing this for a good portion of 600 photos just takes a while, even with the help of a WhiBal. I’ll have to figure a more streamlined approach to processing.
The photos from St. Petersburg will be coming up a bit later.

PHP-GTK 2 Zeta (Yes, Zeta)

15 July 2006 » In PHP » 4 Comments

PHP-GTK 2 Zeta release, the first one of the new architecture, is finally out. No, zeta it’s not a typo. What’s a zeta? Well, it’s a letter of the Greek alphabet. Why zeta? Because, a) we’ve gone through several “iterations” of this release without actually releasing anything, but more importantly, b) alpha and beta get all the glory in the software world, leaving the other Greek letters longing for a spot in the sunshine. So, zeta it is.
While preparing this release I looked at the very end of the NEWS file and realized that I have been working on this project for over 5 years now. That is a sobering thought, which reminds me that I need to go and set up my place for the party tonight in preparation of imbibing copious amounts of mood-altering substances better knows as beers. Cheers.

Hot and .. Not So

15 July 2006 » In Funny, Tech » 4 Comments

Thought I’d throw a couple of fun links your way. First one is a project that almost won $5,000 prize at the last Mashup Camp. It presents, shall we say, an innovative approach to user validation combining so-called business with so-called pleasure. HotCaptcha gets thumbs-up from me any day of the week.
The other is a supremely strong candidate for the title of the Worst Music Video Ever. It is an inspired effort that immediately induces cringing expression on your face and fails to release you from its grip until (in my case) 3 hours later. Have fun.

All the Little Pieces, or TextIterator in PHP 6

13 July 2006 » In PHP » 11 Comments

I have been working on the Unicode support in PHP for quite a while now and I figure that it is time to start talking about Unicode and I18N in general and specifically about some of the new features that PHP 6 will be bringing to the table.
First up is the new Swiss-army knife-like TextIterator class. The purpose of this class is to provide access to various text units in a generic fashion. Actually, I lied. TextIterator implements ICU‘s full boundary analysis API, so what it really gives you are the boundaries between the text units. A slight distinction, but well worth remembering. And what are these units, might you ask?

  • codepoints
  • combining sequences
  • characters (slightly different than combining sequences)
  • words
  • line breaks
  • sentences

As its name tells you, TextIterator also implements PHP’s Iterator interface and thus can be used in such constructs as foreach(). As a quick example, let’s go through a string and extract all words contained in it (skipping empty pieces). Using foreach() it is as simple as:


$str = "The quick brown fox jumped over the lazy dog.";
foreach (new
TextIterator($str, TextIterator::WORD)
as
$num => $word) {
if (
$word[0] != " ") {
printf("%d. %s\n", $num, $word);
}
}


The result is:

0. The
2. quick
4. brown
6. fox
8. jumped
10. over
12. the
14. lazy
16. dog
17. .

Continue reading “All the Little Pieces, or TextIterator in PHP 6” »

Yahoo! Looking for PHP Talent

11 July 2006 » In PHP » No Comments

Yahoo Site Operations Group needs a top-class PHP developer. Here is the official job description:

Yahoos Site Operations Group is looking for a software engineer to build and support existing tools for the Operations groups. You will be responsible for the design, implementation and ongoing maintenance and operation of internal web-based applications targeted at an operations/service-engineering audience. If you thrive on fast-paced development, challenging projects, and being part of a fun and highly-skilled team, read on.
This position will require development of scalable database-driven web applications able to communicate with various backend systems via web services, direct database connections, etc. You should be comfortable with all aspects of the development cycle from requirements-gathering and specification design to implementation and ongoing development.
The ideal candidate will be comfortable working in a cross-functional environment as part of a team composed of project managers, senior engineers, database architects, tech writers, etc. You should be able to identify and fill gaps, find innovative solutions for design problems, work well independently with an eye for high-level objectives, and consistently deliver quality products in a timely fashion.
Required Qualifications
– 5+ years of industry experience building top quality web apps
– Proven expertise with PHP and MySQL
– Expert level UI skills (HTML, CSS, JavaScript)
– Knowledge of C/C++ is a big plus
– Experience with object oriented design and development (PHP/C++)
– Experience with data modeling and advanced query design, optimization, and benchmarking
– Web Services (REST, SOAP, XML_RPC, etc) experience
– Expertise in at least one Unix shell scripting language (bash, PHP CLI, Perl, etc)
– Understand software engineering life cycle, client/server application and Internet application architectures (TCP/IP, HTTP, etc)
– Significant experience with requirements analysis, design, coding, testing, documentation, and application maintenance
– Experience with Linux/Unix/BSD system administration and shell scripting, Apache, and basic database administration
– BS or MS in Computer Science
– Excellent self-motivating, multi-tasking, communication, and interpersonal skills

If that sounds like you, send me a resume and I’ll forward it to the hiring manager.

Sara joins Yahoo!

10 July 2006 » In PHP, Work » No Comments

This may be known to some of you already, but Sara Golemon, author of runkit, classkit, ssh2, and other PECL packages as well as a regular contributor to PHP core, has started at Yahoo! today. She’ll be working in the Search & Marketplace Group and will be a valuable addition to the team. Welcome, Sara!