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

[4.0b] TinyMCE stripping away onclick attribute #29557

Closed
regularlabs opened this issue Jun 10, 2020 · 7 comments
Closed

[4.0b] TinyMCE stripping away onclick attribute #29557

regularlabs opened this issue Jun 10, 2020 · 7 comments

Comments

@regularlabs
Copy link
Contributor

regularlabs commented Jun 10, 2020

After entering html code in the html view that contains onclick attributes, and then switching to the WYSIWYG view (toggle editor), these attributes are removed.

<button class="btn btn-secondary" onclick="console.log('why does this get removed?')">My Button</button>

Results in:

<button class="btn btn-secondary">My Button</button>

This happens as a Super Admin, even though the global Text Filters is set to 'No Filtering'. That seems to have no effect at all.
image

In the TinyMCE plugin settings the 'Use Joomla Text Filter' option is switched off.
image

@regularlabs
Copy link
Contributor Author

PS: Might be connected to: #26185

@Quy
Copy link
Contributor

Quy commented Jun 10, 2020

In the TinyMCE plugin under Set 0, enable Use Joomla Text Filter.

@regularlabs
Copy link
Contributor Author

Wow, would never have found that. Very confusing on multiple levels!

@AndySDH
Copy link
Contributor

AndySDH commented Jun 10, 2020

Yeah, it's really not clear that those are Tabs in the first place, and then when you realize they're Tabs, you still don't understand where they start or end!

@AndySDH
Copy link
Contributor

AndySDH commented Jun 10, 2020

In the TinyMCE plugin under Set 0, enable Use Joomla Text Filter.

I'm surprised you were able to figure it out 😂

@Quy
Copy link
Contributor

Quy commented Jun 10, 2020

PR #28721 enables this setting by default on new installs.

@Quy
Copy link
Contributor

Quy commented Jun 10, 2020

Existing sets of the TinyMCE panel, and options for each set.
In each set you can add or remove from the available menus and buttons.

They look like tabs to me. Plus, the description above tabs hinted they are tabs. You can also check out the Help documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants