force class in elements for TinyMCE

/ Published in: JavaScript
Save to your folder(s)

Copy this code and paste it in your HTML
  1. <script type="text/javascript">
  2. tinyMCE.init({
  3. mode: "textareas",
  4. theme: "simple",
  5. extended_valid_elements: "img[class=myclass]",
  6. invalid_elements: "strong,b,em,i"
  7. });
  8. </script>


Report this snippet


RSS Icon Subscribe to comments

You need to login to post a comment.