Improved code and remove also style tags.
Added testcases.