fix a rotation bug and add html