How to disable editor

140 views Asked by At

I use django-tinymce to input formatted text. I need to disable whole field in form and all editor buttons but can't find how. If anyone has idea about how it can be done, please help.

1

There are 1 answers

1
Joyfulgrind On

You have to use HTML read only attribute. Here's a trick to do that via widget:

myform.fields['status'].widget.attrs['readonly'] = True