## Installing intl for PHP on OS X

Pecl will only try to install PHP extensions in /usr. But OS X's security model prevents that. This work-around works around the problem and installs extensions in different spot.

## UTF-8 Everywhere

Apache, PHP, and web browsers default to ISO-Latin-1 (aka latin1). MySQL defaults to latin1, with the latin1_swedish_ci collation.

## Run tests when they are saved

Python's watchdog module includes watchmedo, a command that watches files or directories. I like to use it to automatically run a test when the test is saved: [shell] $watchmedo shell-command \ --patterns="*.py" \ --recursive \ --command='echo "${watch_src_path}"; python "\${watch_src_path}"' \ tests/ [/shell]

## Perl Boilerplate

Mike Friedman posted about cleaning up Perl boilerplate and switching to Import::Into.

## PHP and session.cookie_path - Heisenbug.

TIL: PHP's session.cookie_path defaults to '/', which is good. But if session.cookie_path is the empty string (''), then the cookie path is set relative to the current URL. If the request is to example.com/foo/bar/bax.php and the cookie path is '', then the cookie is set for example.com/foo/bar - not example.com/ as one might expect. But then the browser goes and saves it forever. And you can the same cookie id on multiple paths and then the expire and maybe some get reset during a logout/login cycle.