Fix deprecations and encoding error

Fixes several instances of deprecated Django implementation.
Also solves a really huge utf-8 decoding problem that may or may not be a problem for anyone besides me.