<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
@font-face
        {font-family:"}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style></head><body lang=EN-US link=blue vlink="#954F72"><div class=WordSection1><p class=MsoNormal>Holger, Andreas, files converted JSON -> XML in Chrome and Firefox have CDATA sections, but Edge doesn’t have CDATA sections when looking at serialized XML text, from my several time look.   We need a better hack below in X3DJSONLD for Edge, I think, but investigate below:</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>function CDATACreateFunction(document, element, str) {</p><p class=MsoNormal>        var y = str.replace(/\\"/g, "\\\"")</p><p class=MsoNormal>                .replace(/&lt;/g, "<")</p><p class=MsoNormal>                .replace(/&gt;/g, ">")</p><p class=MsoNormal>                .replace(/&amp;/g, "&");</p><p class=MsoNormal>        do {</p><p class=MsoNormal>                str = y;</p><p class=MsoNormal>                y = str.replace(/'([^'\r\n]*)\n([^']*)'/g, "'$1\\n$2'");</p><p class=MsoNormal>                if (str !== y) {</p><p class=MsoNormal>                        // console.error("CDATA Replacing",str,"with",y);</p><p class=MsoNormal>                }</p><p class=MsoNormal>        } while (y != str);</p><p class=MsoNormal>       <span style='color:#C00000'> var domParser = new DOMParser();</span></p><p class=MsoNormal><span style='color:#C00000'>        var cdataStr = '<script> <![CDATA[ ' + y + ' ]]> </script>'; // has to be wrapped into an element<o:p></o:p></span></p><p class=MsoNormal><span style='color:#C00000'>        var scriptDoc = domParser .parseFromString (cdataStr, 'application/xml');<o:p></o:p></span></p><p class=MsoNormal><span style='color:#C00000'>        var cdata = scriptDoc .children[0] .childNodes[1]; // space after script is childNode[0]<o:p></o:p></span></p><p class=MsoNormal>        element .appendChild(cdata);</p><p class=MsoNormal>}</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Holger, there may be an issue with:</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>                browser.replaceWorld(browser.createX3DFromString(content));  // where content is XML</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>in the Edge browser for X_ITE.  No problems with Chrome or Firefox in that regard.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>This is with 4.1.5.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>You can see it online here:  <a href="https://coderextreme.net/X3DJSONLD/src/main/html/index.html">https://coderextreme.net/X3DJSONLD/src/main/html/index.html</a></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Select ../data/flowers2.json from the upper left selection (this is converted to XML (not DOM, although I could) and loaded into X_ITE).  If you paste flowers2.x3d into the XML section, you might see that the flowers aren’t colored, but black and white for some reason (PROTOs?).  Note that you may have to reload because failed replaceWorlds will freeze the canvas, I think.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Also ../data/force.json has no animation with Edge and the XML version.  I feel this may be the CDATA above, but it also may be due to an initializeOnly field on an Extrusion (spine).</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>These errors may be due to initializeOnly fields (modifying Extrusion spline, IFS coordIndexes) which aren’t tested with browser.importJS??? (not sure—may want to check).  Note that X3DJSAIL does not validate flowers2.json (converted to flowers2.java), so likely there’s an issue with that file.  I’m also getting <span style='font-size:9.0pt;font-family:Consolas;color:#FF0505'>XML5656: Illegal qualified name character. </span><span style='font-size:9.0pt;font-family:Consolas'>And <span style='color:#FF0505'>[object Error]: </span></span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#2B91AF'>{</span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#1E1E1E'>description: </span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#A31515'>"Unable to get property 'setup' of undefined or null reference"</span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#1E1E1E'>, message: </span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#A31515'>"Unable to get property 'setup' of undefined or null reference"</span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#1E1E1E'>, number: </span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#A31515'>-2146823281</span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#1E1E1E'>, stack: </span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#A31515'>"TypeError: Unable to get property 'setup' of undefined or null reference at createX3DFromString (https://cdn.rawgit.com/create3000/x_ite/4.1.5/dist/x_ite.min.js:43:22971) at Anonymous function (http://localhost:3000/node/loaderJQuery.js:204:3) at h (https://cdn.rawgit.com/create3000/x_ite/4.1.5/dist/x_ite.min.js:4:24940) at c.add (https://cdn.rawgit.com/create3000/x_ite/4.1.5/dist/x_ite.min.js:4:25057) at T (https://cdn.rawgit.com/create3000/x_ite/4.1.5/dist/x_ite.min.js:43:29332) at t (https://cdn.rawgit.com/create3000/x_ite/4.1.5/dist/x_ite.min.js:43:30467) at load_X_ITE_XML (http://localhost:3000/node/loaderJQuery.js:202:2) at loadXmlBrowsers (http://localhost:3000/node/loaderJQuery.js:80:4) at Anonymous function (http://localhost:3000/node/loaderJQuery.js:290:8) at Anonymous function (http://localhost:3000/node/loaderJQuery.js:438:3)"</span><span style='font-size:9.0pt;font-family:"&quot",serif;color:#2B91AF'>}</span><span style='font-size:9.0pt;font-family:Consolas'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:9.0pt;font-family:Consolas'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:9.0pt;font-family:Consolas'>Again, all this is working fine in Chrome and Firefox as far as I know.  Well X3DOM isn’t currently working in Chrome. Sigh!<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:9.0pt;font-family:Consolas'><o:p> </o:p></span></p><p class=MsoNormal>Thanks,</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>John</p></div></body></html>