Make encoding work (with testing) under php 5.3.