1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2024-06-14 15:44:49 +02:00

Add namespace attribute to XHTML-IM body tags

Fixes SMACK-531
This commit is contained in:
Florian Schmaus 2014-02-10 13:51:12 +01:00
parent 4bc7ce052d
commit 7ba3c3d43f

View file

@ -27,6 +27,8 @@ import org.jivesoftware.smack.util.StringUtils;
*/ */
public class XHTMLText { public class XHTMLText {
private static final String NAMESPACE = "http://www.w3.org/1999/xhtml";
private StringBuilder text = new StringBuilder(30); private StringBuilder text = new StringBuilder(30);
/** /**
@ -100,7 +102,7 @@ public class XHTMLText {
* @param lang the language of the body * @param lang the language of the body
*/ */
private void appendOpenBodyTag(String style, String lang) { private void appendOpenBodyTag(String style, String lang) {
StringBuilder sb = new StringBuilder("<body"); StringBuilder sb = new StringBuilder("<body xmlns=\"" + NAMESPACE + "\"");
if (style != null) { if (style != null) {
sb.append(" style=\""); sb.append(" style=\"");
sb.append(style); sb.append(style);