To add an editor there is this code
Code: Select all
<!-- Include stylesheet -->
<link href="https://cdn.quilljs.com/1.2.6/quill.snow.css" rel="stylesheet">
<!-- Create the editor container -->
<div id="editor">
<p>Hello World!</p>
<p>Some initial <strong>bold</strong> text</p>
<p><br></p>
</div>
<!-- Include the Quill library -->
<script src="https://cdn.quilljs.com/1.2.6/quill.js"></script>
<!-- Initialize Quill editor -->
<script>
var quill = new Quill('#editor', {
theme: 'snow'
});
</script>
Code: Select all
<div id="editor">
<p>Hello World!</p>
<p>Some initial <strong>bold</strong> text</p>
<p><br></p>
</div>
This code works, but it is crooked if it is inserted as is
The question is how to insert so that the editor works on the editing panel, and not separately from it?
There is another template template - Bubble
Code: Select all
<!-- Add the theme's stylesheet -->
<link rel="stylesheet" href="//cdn.quilljs.com/1.2.6/quill.bubble.css">
<script src="//cdn.quilljs.com/1.2.6/quill.js"></script>
<script>
var quill = new Quill('#editor', {
theme: 'bubble' // Specify theme in configuration
});
</script>
Code: Select all
<div id="editor">
<p>Hello World!</p>
<p>Some initial <strong>bold</strong> text</p>
<p><br></p>
</div>