fix to handle XHTML
replace entity not available for XHTML
Merge pull request #176 from parly/master

Fix to handle XHTML