Opened 9 years ago
Closed 9 years ago
#13738 closed Bug (invalid)
HTML & JavaScript code disappears completely on Source switch.
Reported by: | kenorb | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | |
Keywords: | Cc: |
Description
Steps to reproduce
- Go to: http://ckeditor.com/demo
- Switch to Source.
- Paste the code from: https://gist.github.com/kenorb/f9e028b90585c73aaae3
- Toggle Source, the code is gone.
Expected result
The code should stay.
Actual result
The code is gone.
Other details (browser, OS, CKEditor version, installed plugins)
Chrome on OS X.
Attachments (1)
Change History (2)
Changed 9 years ago by
Attachment: | google-map-code.js added |
---|
comment:1 Changed 9 years ago by
Resolution: | → invalid |
---|---|
Status: | new → closed |
Version: | 4.5.3 |
First of all, please read about ACF:
http://docs.ckeditor.com/#!/guide/dev_acf
http://docs.ckeditor.com/#!/guide/dev_advanced_content_filter
http://docs.ckeditor.com/#!/guide/dev_disallowed_content
http://docs.ckeditor.com/#!/api/CKEDITOR.filter-method-addTransformations
http://docs.ckeditor.com/#!/api/CKEDITOR.config-cfg-allowedContent
http://docs.ckeditor.com/#!/api/CKEDITOR.config-cfg-extraAllowedContent
http://nightly.ckeditor.com/14-03-20-07-05/full/samples/datafiltering.html
Second, set the extraallowedContent e.g. extraAllowedContent : 'div[*](*){*};script[*](*){*}'
Finally, please note that Java Script will not be executed in wysiwyg mode (This is by design). You can check how it works using the preview plugin.
HTML code which disappears on Source toggle.