Index: _dev/msajax.js
===================================================================
--- _dev/msajax.js (revision 7082)
+++ _dev/msajax.js (working copy)
@@ -16,7 +16,7 @@
}
else {
var e = CKEDITOR.instances[cID];
- if (inUpdatePanel) {
+ if (e && Page_IsValid) {
e.destroy();
control = document.getElementById(cID);
if (control)
Index: CKEditor.NET/CKEditorControl.cs
===================================================================
--- CKEditor.NET/CKEditorControl.cs (revision 7082)
+++ CKEditor.NET/CKEditorControl.cs (working copy)
@@ -1030,7 +1030,7 @@
// Sys.Application.add_load does not work on browsers != IE
// http://msdn.microsoft.com/en-us/library/bb386417.aspx
// Check _dev/msajax.js for an uncompressed version (available in CKEditor.Net downloaded from SVN).
- scriptInit += @"var CKEditor_Controls=[],CKEditor_Init=[];function CKEditor_TextBoxEncode(d,e){var f;if(typeof CKEDITOR=='undefined'||typeof CKEDITOR.instances[d]=='undefined'){f=document.getElementById(d);if(f)f.value=f.value.replace(//g,'>');}else{var g=CKEDITOR.instances[d];if(e){g.destroy();f=document.getElementById(d);if(f)f.style.visibility='hidden';}else g.updateElement();}};(function(){if(typeof CKEDITOR!='undefined'){var d=document.getElementById('" + this.ClientID + @"');if(d)d.style.visibility='hidden';}var e=function(){var f=CKEditor_Controls,g=CKEditor_Init,h=window.pageLoad,i=function(){for(var j=f.length;j--;){var k=document.getElementById(f[j]);if(k&&k.value&&(k.value.indexOf('<')==-1||k.value.indexOf('>')==-1))k.value=k.value.replace(/</g,'<').replace(/>/g,'>').replace(/&/g,'&');}if(typeof CKEDITOR!='undefined')for(var j=0;j/g,'>');}else{var g=CKEDITOR.instances[d];if(e && Page_IsValid){g.destroy();f=document.getElementById(d);if(f)f.style.visibility='hidden';}else g.updateElement();}};(function(){if(typeof CKEDITOR!='undefined'){var d=document.getElementById('" + this.ClientID + @"');if(d)d.style.visibility='hidden';}var e=function(){var f=CKEditor_Controls,g=CKEditor_Init,h=window.pageLoad,i=function(){for(var j=f.length;j--;){var k=document.getElementById(f[j]);if(k&&k.value&&(k.value.indexOf('<')==-1||k.value.indexOf('>')==-1))k.value=k.value.replace(/</g,'<').replace(/>/g,'>').replace(/&/g,'&');}if(typeof CKEDITOR!='undefined')for(var j=0;j