Comments (5)
can you post your editor config? and also can you post the content that is is added, or make a screen shot?
from ckeditor-textselection-plugin.
Ok - here are all the details. Let me know if you need anything else from me to help you fix it:
The error I'm finding only appears once I add the textselection plugin. As soon as I remove it, everything works great.
The problem is when you put <iframe src="anything"></iframe> in the source and then switch to HTML view and then back. You can see what happens because it looks like this:
<p><iframe src="http://www.google.com "><!--{cke_protected}{C}%3C!%2D%2Dcke_bookmark_99S%2D%2D%3E--><!--{cke_protected}{C}%3C!%2D%2Dcke_bookmark_99E%2D%2D%3E--></iframe ></p>
(Note: I had to add the space after the http://www.google.com URL to make the code render the above correctly in Github)
These are all the plugins I have installed. I did a minimum install of CKEditor 4.3.1 and manually added these back in (yes, I know, a lot of extra work).
config.plugins = 'dialogui,dialog,floatpanel,a11yhelp,dialogadvtab,menubutton,basicstyles,stylescombo,bidi,blockquote,clipboard,button,panelbutton,panel,colorbutton,colordialog,templates,menu,contextmenu,div,resize,toolbar,elementspath,list,indent,indentblock,indentlist,enterkey,entities,popup,find,fakeobjects,flash,listblock,richcombo,font,forms,format,htmlwriter,horizontalrule,iframe,wysiwygarea,image,smiley,justify,link,liststyle,magicline,maximize,pagebreak,pastetext,pastefromword,preview,print,removeformat,save,selectall,showblocks,showborders,sourcedialog,specialchar,tab,table,tabletools,undo,onchange,htmlbuttons,codemirror,autogrow,tableresize,iframedialog,docprops,wsc,scayt,xml,ajax,placeholder,stylesheetparser,textselection';
config.skin = 'moonocolor';
And this is now I instantiate it:
var editor = CKEDITOR.replace('Notes',{ uiColor : '#d3e1f5', language : '$language' , width : '90%' , height : '300px' , autoGrow_minHeight: 300 , autoGrow_maxHeight : maxHeight , autoGrow_bottomSpace: 0 , autoGrow_onStartup : true , resize_dir : 'both' , resize_minHeight : 200 , dialog_backgroundCoverColor : '#d7e6f9' , dialog_backgroundCoverOpacity : 0.75 , colorButton_enableMore : true , tabSpaces : 5 , fullPage : false , autoUpdateElement : true , toolbarStartupExpanded : true , filebrowserImageUploadUrl : 'uploadImageToEditor.pl' , extraPlugins : 'simpleuploads,imageloader,tableresize,countdown,linker,articleloader,mailmerge,loadwiki,wordcount,doksoft_maps' , toolbar : [ ['Bold','Italic','Underline','Strike','-','Subscript','Superscript'] , ['NumberedList','BulletedList'], ['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'] , ['Cut','Copy','Paste','PasteText','PasteFromWord'] , ['Undo','Redo'], ['Find','Replace','Scayt'] , '/', ['linker','Unlink','Anchor'] , ['Table','HorizontalRule','Smiley','SpecialChar'] , ['doksoft_maps'] , ['countdown'] , ['mailmerge'] , ['loadwiki'] , ['articleloader'] , ['imageloader'] , '/', ['Styles','Format','Font','FontSize'], ['TextColor','BGColor'], ['RemoveFormat','-','ShowBlocks'], ['Source'] ]});
from ckeditor-textselection-plugin.
Thanks iam able to reproduce looks like it only happens when the cursor is inside the iframe tags. then the ckeditor is adding the protected source code and encodes the content. But this is not an issue of the plugin. this is a bug in the editor
Try this.
- Open the editor demo - http://ckeditor.com/demo
- Switch to Source
- Enter
<iframe src="http://google.de"><!-- Hello -->This is atest</iframe>
- switch to wysiwyg mod and the content is changed to
<iframe src="http://google.de"><!--{cke_protected}{C}%3C!%2D%2D%20Hello%20%2D%2D%3E-->This is atest</iframe>
This should be reported in the ckeditor tracker not here. Sorry but i can't fixed that.
from ckeditor-textselection-plugin.
That is not my experience. It works fine without the TextSelection plugin enabled.
Now, I think you are right with leaving the cursor inside an iframe tagset and putting comment tags in there, but the cke_protected cke_bookmark_99 thing appears whenever you change from Source to WYSIWYG to Source regardless of where the cursor is.
from ckeditor-textselection-plugin.
I reported this issue on the CKEditor bug tracker
https://dev.ckeditor.com/ticket/11442
I closed the issue because this is nothing i can fix from my plugin.
from ckeditor-textselection-plugin.
Related Issues (20)
- decodeURIComponent fails if source text contains % HOT 4
- Cursor position only works to first tag on return to WYSIWYG HOT 4
- Could this work with other source code plugins? HOT 2
- scroll caret / selection into view HOT 4
- If cursor is in the <head> section of a FullPage document, extra code is added HOT 8
- Selected text is removed in IE10 and IE11 HOT 1
- cke_bookmarks HOT 15
- Content lost when clicking undo after switching from WYSIWYG to SOURCE and back to WYSIWYG HOT 2
- cursor misplaced returning from sourcodeview HOT 4
- Switching from Source to WYSIWIG and back duplicates TABLE/TR/TD HOT 2
- Turning to Source when a widget is focused adds empty paragraphs around it HOT 4
- Storing content in browser local storage does not work properly / sporadically loses changes without local storage HOT 4
- fullPage = true compatibility HOT 3
- The plugin seems to prevent the content from changing when switching to source and back? HOT 4
- Dropping selection when switching to WYSIWYG if the selection starts or ends with the HTML element HOT 3
- Selection/Position not kept if fullPage: true in CKEditor config HOT 2
- Bookmark Spans not getting removed HOT 2
- CKEditor 5 upgrade HOT 2
- TextSelection doesn't work in SourceDialog with CodeMirror HOT 7
- Hi, In source mode, How to autoscroll the selection? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ckeditor-textselection-plugin.