Removed BeautifulSoup dependency, improved HTML encoding in strotoimg.py