Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

142
Views
Envuelva automáticamente "clase div" alrededor de la mesa dentro de TinyMCE 5

Estoy usando el editor TinyMCE 5.

Ahora estoy tratando de encontrar una solución para que el editor envuelva automáticamente una tabla con un determinado "contenedor div".

Lo intenté así:

 tinyMCE.init({ selector: '#myTextarea', plugins: 'table code autolink link lists charmap print preview textcolor code', toolbar: 'table code link | undo redo | insert | code', menubar: false, min_height: 300, setup: function (ed) { ed.on("keyup", function () { var contentmain = tinymce.activeEditor.getContent(); $('#preview').html(contentmain); }); ed.on("keyup", function () { $('.tabledefaultg').wrap('<div class="scroll-bar"></div>'); }); } });

El problema es que <div class="scroll-bar"> no se agrega dentro del código fuente de los editores. Simplemente se agrega dentro del contenedor de "vista previa".

¿Como puedo solucionar este problema?

Este es el JSFiddle .

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!