簡體   English   中英

在Internet Explorer 10中僅顯示“正在加載”

[英]Only showing “Loading” in Internet Explorer 10

我有一個問題,就是我的JStree可以在除Internet Explorer 10之外的所有瀏覽器中使用。它僅在啟用兼容模式的情況下工作。 我不想使用兼容模式來運行JStree。 我怎么解決這個問題? 在Internet Explorer 10中,它僅顯示“正在加載”,但在Internet Explorer 8和其他瀏覽器中,它可以正確展開

我已經知道答案是因為jstree ..您需要在jstree加載代碼中放入一些代碼..解決方案是

if(window.ActiveXObject) {
            $.vakata.xslt = function (xml, xsl, callback) {
                var rs = "", xm, xs, processor, support;

                var xslt = new ActiveXObject("Msxml2.XSLTemplate");
                var xmlDoc = new ActiveXObject("Msxml2.DOMDocument");
                var xslDoc = new ActiveXObject("Msxml2.FreeThreadedDOMDocument");
                xmlDoc.loadXML(xml);
                xslDoc.loadXML(xsl);
                xslt.stylesheet = xslDoc;
                var xslProc = xslt.createProcessor();
                xslProc.input = xmlDoc;
                xslProc.transform();
                callback.call(null, xslProc.output);

                return true;
            }
        }

和它的工作!

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM