Days
Hours
Minutes
Seconds
x

Froala Editor v4.2.0 is Here LEARN MORE

Skip to content

Buttons

Subscript and Superscript

Try it yourself:


Edit in JSFiddle

HTML

<div id="froala-editor">
  <p>To use <code>subscript</code> and <code>superscript</code>, just make sure that you include these buttons in the buttons list using the <a href="../docs/options#toolbarButtons" title="toolbarButtons option" target="_blank">toolbarButtons</a> option.</p>
</div>

JAVASCRIPT

<script>
  new FroalaEditor('div#froala-editor', {
    // Include the subscript and superscript buttons.
    toolbarButtons: [['bold', 'italic', 'subscript', 'superscript'], ['indent', 'outdent', 'formatOL', 'formatUL']]
  })
</script>