Sonata – add CKEditor in admin textareas

CKEditor is one of the best wysiwyg. It is possible to use CKEditor with sonataFormatterBundle, but there is an easier way to add CKEditor in Sonata admin textareas. Add the file: Acme/AdminBundle/Resources/views/CRUD/edit.html.twig {% extends ‘SonataAdminBundle:CRUD:base_edit.html.twig’ %} {% block javascripts %} {{ parent() }} <script src=”//cdn.ckeditor.com/4.5.0/standard/ckeditor.js”></script> <script type=”text/javascript”> $(function() { $(‘textarea.ckeditor’).ckeditor(); }); </script> {% endblock %}…