CoreyMSchafer/code_snippets

Integrating A Rich Text Editor For Blog Posts?

Closed this issue · 2 comments

Does anybody know how to integrate a rich text editor for creating blog posts?
Since this tutorial uses Flask WTForms it's a bit confusing to me.

Use tinyMCE

Okay I figured it out.

I had to use {{ form.content(id="editor", class="form-control form-control") }} on "create_post.html"

and then add the following:

{% block js %}
<script src="//cdn.ckeditor.com/4.4.7/standard/ckeditor.js">
</script>
<script>
    CKEDITOR.replace('editor');
</script>
{% endblock %}