Try to support more encodings