====== CKEditor 4 ====== Doc : [[https://ckeditor.com/docs/ckeditor4/latest/|Documentation de CKEditor 4]] ===== Installation ===== Aller sur [[https://ckeditor.com/ckeditor-4/download/]] et télécharger le **Standard Package** : cd /mon_projet/public wget https://download.cksource.com/CKEditor/CKEditor/CKEditor%204.14.0/ckeditor_4.14.0_standard.zip Décompresser le fichier : unzip ckeditor_4.14.0_standard.zip Le contenu se trouve dans **mon_projet/public/ckeditor/** : public/ ckeditor/ Aller à l'adresse [[http://127.0.0.1:8000/ckeditor/samples/]] pour tester et avoir un aperçu des fonctionnalités. ===== Intégration dans un formulaire ===== Formulaire : {% block body %}

Article

{{ form_start(form) }} ... {# L'ID de ce champ est "edit_contenu" #} {{ form_label(form.contenu) }} ... {{ form_end(form) }} {% endblock %}
Block ''javascripts'' : {% block javascripts %} {% endblock %} Configuration dans **ckeditor/ck_upload.php** : // Define the upload path $upload_dir = array( 'img' => 'uploads/', ); ...