summaryrefslogtreecommitdiff
path: root/protected/extensions/extckeditor/assets/plugins/xml
diff options
context:
space:
mode:
authorPatrick Seeger <pseeger@ccwn.org>2012-04-30 16:59:07 +0200
committerPatrick Seeger <pseeger@ccwn.org>2012-04-30 16:59:07 +0200
commit10b3e68c049cc0830584e535b9273ec1c7745450 (patch)
tree59d9eb85033dbc02b33eb7a92c252d87bd835ba0 /protected/extensions/extckeditor/assets/plugins/xml
parent2a8b46329775b8503519d432a52dba13e8547d8e (diff)
cms fixes + suche
Diffstat (limited to 'protected/extensions/extckeditor/assets/plugins/xml')
-rw-r--r--protected/extensions/extckeditor/assets/plugins/xml/plugin.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/protected/extensions/extckeditor/assets/plugins/xml/plugin.js b/protected/extensions/extckeditor/assets/plugins/xml/plugin.js
new file mode 100644
index 0000000..e27371d
--- /dev/null
+++ b/protected/extensions/extckeditor/assets/plugins/xml/plugin.js
@@ -0,0 +1,6 @@
+/*
+Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved.
+For licensing, see LICENSE.html or http://ckeditor.com/license
+*/
+
+(function(){CKEDITOR.plugins.add('xml',{});CKEDITOR.xml=function(a){var b=null;if(typeof a=='object')b=a;else{var c=(a||'').replace(/&nbsp;/g,'\xa0');if(window.DOMParser)b=new DOMParser().parseFromString(c,'text/xml');else if(window.ActiveXObject){try{b=new ActiveXObject('MSXML2.DOMDocument');}catch(d){try{b=new ActiveXObject('Microsoft.XmlDom');}catch(d){}}if(b){b.async=false;b.resolveExternals=false;b.validateOnParse=false;b.loadXML(c);}}}this.baseXml=b;};CKEDITOR.xml.prototype={selectSingleNode:function(a,b){var c=this.baseXml;if(b||(b=c))if(CKEDITOR.env.ie||b.selectSingleNode)return b.selectSingleNode(a);else if(c.evaluate){var d=c.evaluate(a,b,null,9,null);return d&&d.singleNodeValue||null;}return null;},selectNodes:function(a,b){var c=this.baseXml,d=[];if(b||(b=c))if(CKEDITOR.env.ie||b.selectNodes)return b.selectNodes(a);else if(c.evaluate){var e=c.evaluate(a,b,null,5,null);if(e){var f;while(f=e.iterateNext())d.push(f);}}return d;},getInnerXml:function(a,b){var c=this.selectSingleNode(a,b),d=[];if(c){c=c.firstChild;while(c){if(c.xml)d.push(c.xml);else if(window.XMLSerializer)d.push(new XMLSerializer().serializeToString(c));c=c.nextSibling;}}return d.length?d.join(''):null;}};})();