Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow any html tags to be used in the content #681

Closed
moesjarraf opened this issue Nov 20, 2017 · 3 comments
Closed

Allow any html tags to be used in the content #681

moesjarraf opened this issue Nov 20, 2017 · 3 comments
Labels
resolution:invalid This issue is invalid (e.g. reports a non-existent bug or a by-design behavior).

Comments

@moesjarraf
Copy link

moesjarraf commented Nov 20, 2017

Hi,

In the previous ckeditor version there was a config option which allowed any html tags to be used in the content, as is, without overwriting/modifying the tags. The config options were called allowedContent and extraAllowedContent. It was also possible to set a fullPage option, so <html> and <head> tags were allowed.

Are these properties still supported in some way? If not, how would I achieve a similar effect?

@scofalik
Copy link
Contributor

Hi, inserting arbitrary HTML is not possible in CKE5. This is for a few reasons.

Mostly because CKE5, in contrary to v4, operates basing on a custom data model. Each "feature" has its own representation in custom data tree inside the editor. That means that the editor no longer "understands" any HTML, as every HTML bit has to be translated to an element in the model tree.

Other three reasons are:

  • focusing more on content creation, not HTML creation,
  • trying to produce semantically correct HTML,
  • complications in algorithms - we want our features to work perfectly, which is difficult when any HTML can be inserted into the editor.

@Reinmar gives some more insight on this here: #592 (comment). You may want to read the whole discussion to learn more about our approach.

Of course, there's always a way around. It would be possible to provide a plugin which will convert all unrecognized elements/classes/styles to elements/attributes in the model and then back to the view. However, it is not something that we would recommend, encourage to, or put in official builds.

@scofalik
Copy link
Contributor

Similar question was raised here: #664

@Reinmar Reinmar added the resolution:invalid This issue is invalid (e.g. reports a non-existent bug or a by-design behavior). label Nov 21, 2017
@iridescentapps
Copy link

@scofalik Is there any sample example where we can implement and enable some basic HTML tags like input and dropdown.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
resolution:invalid This issue is invalid (e.g. reports a non-existent bug or a by-design behavior).
Projects
None yet
Development

No branches or pull requests

4 participants