version.rst 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. Use your own CKEditor
  2. =====================
  3. The bundle is shipped with the latest CKEditor 4 full release. If you don't want
  4. to use it, the bundle allows you to use your own by defining it in your
  5. configuration file or in your widget.
  6. Install your CKEditor
  7. ---------------------
  8. First of all, you need to download and extract your own CKEditor version in the
  9. public directory. For that, you have two possibilities:
  10. #. Directly put it in the web directory (``/public/ckeditor/`` for example).
  11. #. Put it in the ``/Resources/public/`` directory of any of your bundles and
  12. install the assets.
  13. Register your CKEditor
  14. ----------------------
  15. Then, to use your own CKEditor instead of the built-in, just need to register it
  16. in your configuration or in your widget:
  17. .. code-block:: yaml
  18. # app/config/config.yml
  19. fos_ck_editor:
  20. base_path: "ckeditor"
  21. js_path: "ckeditor/ckeditor.js"
  22. .. code-block:: php
  23. $builder->add('field', 'ckeditor', array(
  24. 'base_path' => 'ckeditor',
  25. 'js_path' => 'ckeditor/ckeditor.js',
  26. ));
  27. .. note::
  28. Each path must be relative to the public directory.