Merge #76: Accept UTF8 as UTF-8 and test encoding with fallback to UTF-8

Fixes #71.

Squashed commit of the following:

commit 9ce3664e296fb190473717bcd08e772184ff8242
Author: Gaute Hope <eg@gaute.vetsj.com>
Date:   Wed May 29 08:33:26 2013 +0200

    test encoding and fallback to utf-8

commit b17e917565e0a13671c0aaf08c22bfbf63ff5bb4
Author: Gaute Hope <eg@gaute.vetsj.com>
Date:   Wed May 29 00:12:16 2013 +0200

    accept UTF8 as UTF-8