Index: /FCKeditor/trunk/_whatsnew.html
===================================================================
--- /FCKeditor/trunk/_whatsnew.html	(revision 846)
+++ /FCKeditor/trunk/_whatsnew.html	(revision 847)
@@ -87,4 +87,6 @@
 		<li>The EditorAreaCSS config option can now also be set to a string of paths separated
 			by commas.</li>
+		<li>[<a target="_blank" href="http://dev.fckeditor.net/ticket/1266">#1266</a>] Introducing
+			the HtmlEncodeOutput setting to instruct the editor to encode the posted data.</li>
 	</ul>
 	<p>
Index: /FCKeditor/trunk/editor/_source/internals/fck.js
===================================================================
--- /FCKeditor/trunk/editor/_source/internals/fck.js	(revision 846)
+++ /FCKeditor/trunk/editor/_source/internals/fck.js	(revision 847)
@@ -247,5 +247,10 @@
 	UpdateLinkedField : function()
 	{
-		FCK.LinkedField.value = FCK.GetXHTML( FCKConfig.FormatOutput ) ;
+		var value = FCK.GetXHTML( FCKConfig.FormatOutput ) ;
+		
+		if ( FCKConfig.HtmlEncodeOutput )
+			value = FCKTools.HTMLEncode( value ) ;
+			
+		FCK.LinkedField.value = value ;
 		FCK.Events.FireEvent( 'OnAfterLinkedFieldUpdate' ) ;
 	},
Index: /FCKeditor/trunk/fckconfig.js
===================================================================
--- /FCKeditor/trunk/fckconfig.js	(revision 846)
+++ /FCKeditor/trunk/fckconfig.js	(revision 847)
@@ -95,4 +95,5 @@
 FCKConfig.PreserveSessionOnFileBrowser = false ;
 FCKConfig.FloatingPanelsZIndex = 10000 ;
+FCKConfig.HtmlEncodeOutput = false ;
 
 FCKConfig.TemplateReplaceAll = true ;
