xslt disable-output-escaping turns non-latin characters into question marks "...???????????..."
I'm using xslt do display Solr response in html, my xsl file is in UTF-8 and non-latin characters (arabic) are nicely displayed, the problem is that when I use disable-output-escaping="yes" to par开发者_高级运维se html tag, the non-latin chars become a series of question marks ?????????
Any clue ?
Thanks in advance
You "non-latin" characters aren't correctly processed by your XSL processor (maybe it's not unicode-aware?), so they get replaced with "?". Escaping will replace those with their unicode counterparts or with XML entities that represent the character.
Your best option here is to force-specify an encoding that is appropriate for your text, and ensure you use an XSL processor that honors that encoding (some poorly written software frequently assume the whole world writes for en_US locales, sadly).
精彩评论