views:

15

answers:

1

Whenever I call getData() on my CKEditor it returns what appears to be some server generated script tags, aswell, and it has on occaision returned the firebug div as well, which seems a bit odd. So I don't think that it is related to asp specifically, but not sure

<script type="text/javascript">  

$(function() {
  if (queryString["fxml"]) {
    $("#ckeditorPH").css("display","block").ckeditor();  
  }  
});  
CKEDITOR.plugins.registered['save'] = {
  init: function(editor) {
            var command = editor.addCommand('save', {
                modes: {
                    wysiwyg: 1, source: 1
                },
                exec: function(editor) {
                    var $ck = $("#ckeditorPH").ckeditorGet();
                    $ck.updateElement();
                    $("#ckeContent").text($ck.getData()).html();
                }
            }
            );
            editor.ui.addButton('Save', { label: 'Save', command: 'save' });
   }
}
</script>


<asp:Content ID="Content3" ContentPlaceHolderID="CPmainContent" Runat="Server">
    <textarea id="ckeditorPH" style="display: none;" name="ckEditorPh" cols="1" rows="3"></textarea>
    <div id="ckeContent"></div>
</asp:Content>

And some example returned code

<div id="footer">  
asdsdasdasd</div> 
<script type="text/javascript"> 
//<![CDATA[ var ctl00_ctl02_ImageArray =  new Array('', '', '', '/Wiki WebResource.axd?d=orvFyKxqjn_MxWN6EePxi9qdFITpyPFIgsCG-7yiV981&t=634031320320031812', '/Wiki/WebResource.axd?d=orvFyKxqjn_MxWN6EePxiziK9rrZZZfuENrSUk7FQmY1&t=634031320320031812', 
'/Wiki/WebResource.axd?d=orvFyKxqjn_MxWN6EePxixV5Wtl1sjTWzAxt10NTBqE1&t=634031320320031812');  
//]]>  
</script>  
<script type="text/javascript"> 
//<![CDATA[  
WebForm_InitCallback();  
var ctl00_ctl02_Data = new Object(); 
ctl00_ctl02_Data.images = ctl00_ctl02_ImageArray;  
ctl00_ctl02_Data.collapseToolTip = "Collapse {0}";  
ctl00_ctl02_Data.expandToolTip = "Expand {0}";  
ctl00_ctl02_Data.expandState = theForm.elements['ctl00_ctl02_ExpandState'];  
ctl00_ctl02_Data.selectedNodeID = theForm.elements['ctl00_ctl02_SelectedNode'];  
for (var i=0;i<6;i++) {  
var preLoad = new Image();  
if (ctl00_ctl02_ImageArray[i].length > 0)  
preLoad.src = ctl00_ctl02_ImageArray[i];  
}  
ctl00_ctl02_Data.lastIndex = 4;  
ctl00_ctl02_Data.populateLog = theForm.elements['ctl00_ctl02_PopulateLog'];  
ctl00_ctl02_Data.treeViewID = 'ctl00$ctl02';  
ctl00_ctl02_Data.name = 'ctl00_ctl02_Data';  
//]]>  
</script>
A: 

The firebug element is due to problems in previous versions of Firebug and the latest 1.6 version fixes it.

For the rest of the scripts: I have never seen something like that.

AlfonsoML