Make HTML generator scripts Python 3 compatible