Lots of bug fixes, and adaptations for utf8 support and php 5.4/5.5 strict mode.