Added htmlStatement functionality and tests