cancel
Showing results for 
Search instead for 
Did you mean: 

Magento 2.3.1, where's tinymce setup.js?

SOLVED

Magento 2.3.1, where's tinymce setup.js?

In magento 2.3.1, installed on aws lightsail using bitnami. I'm trying to disable tinymce from inserting `<p>` tags, and the solution that many agree with is

 

https://stackoverflow.com/a/26396255/1920003

 

 

`forced_root_block : '', /* <-- Add this setting */`

 

to

 

`js/mage/adminhtml/wysiwyg/tiny_mce/setup.js`

 

But there are many setup.js files and none look like the standard setup.js file. I really want to apply this solution because

 

1. I can't upgrade to newer version off magento, I have 50 extensions that will break
2. I can't disable the wysiwyg, there are none technical users editing the site
3. I believe this will work, when I used to create my own hand written CMSes, I used to face a similar problem and fix it like that.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Magento 2.3.1, where's tinymce setup.js?

No, the correct file containing tinymce setup isn't even called setup.js

 

it's

 

`lib/web/mage/adminhtml/wysiwyg/tiny_mce/tinymce4Adapter.js`

 

I added this option on line 206 and the problem seems fixed.

 

FK magento because, 

 

  • if you have extensions or custom theme, they'll break when upgrading 
  • Some of these silly problems no one knows how to answer them, I literally asked this question many places and multiple times on Magento.se,  everyone says it cannot be done.
  • I question most design patterns done by magento team, like what the hell were they thinking about when they decided to name the file tinymce4Adapter and place it in a place that no one can find it and not even mention it on the docs or forums. TinyMCE is the least of my problems with magento though...
  • How the hell they release software with a WYSIWYG targeted for shop owners, and when shop owners start complaining about WYSIWYG breaking their site, they tell them to turn off the editor and learn HTML to get things done.
  • How the hell is the official solution for the problem is to upgrade magento when they know very well that out of all the cms around, magento is the hardest to upgrade, especially when you have themes and extensions, which most decent shops have one or the other. 

 

View solution in original post

2 REPLIES 2

Re: Magento 2.3.1, where's tinymce setup.js?

Hi @elie_obeid 

 

At below directory path tinymce setup.js available:

 

- lib/web/mage/adminhtml/wysiwyg/tiny_mce/setup.js

- vendor/magento/magento2-base/lib/web/mage/adminhtml/wysiwyg/tiny_mce/setup.js

 

Hope it helps!

if issue solved,Click Kudos & Accept as Solution

Re: Magento 2.3.1, where's tinymce setup.js?

No, the correct file containing tinymce setup isn't even called setup.js

 

it's

 

`lib/web/mage/adminhtml/wysiwyg/tiny_mce/tinymce4Adapter.js`

 

I added this option on line 206 and the problem seems fixed.

 

FK magento because, 

 

  • if you have extensions or custom theme, they'll break when upgrading 
  • Some of these silly problems no one knows how to answer them, I literally asked this question many places and multiple times on Magento.se,  everyone says it cannot be done.
  • I question most design patterns done by magento team, like what the hell were they thinking about when they decided to name the file tinymce4Adapter and place it in a place that no one can find it and not even mention it on the docs or forums. TinyMCE is the least of my problems with magento though...
  • How the hell they release software with a WYSIWYG targeted for shop owners, and when shop owners start complaining about WYSIWYG breaking their site, they tell them to turn off the editor and learn HTML to get things done.
  • How the hell is the official solution for the problem is to upgrade magento when they know very well that out of all the cms around, magento is the hardest to upgrade, especially when you have themes and extensions, which most decent shops have one or the other.