egeloen / IvoryCKEditorBundle

Provides a CKEditor integration for your Symfony project.
MIT License
336 stars 114 forks source link

How to add filebrowserVideoBrowseRoute ? #231

Closed raphaelriehl closed 8 years ago

raphaelriehl commented 8 years ago

Hello,

Is it possible to add my own filebrowser route name ? I would like add this :

filebrowserVideoBrowseRoute filebrowserVideoBrowseRouteParameters filebrowserVideoBrowseRouteAbsolute

In pending, I have updated the $keys array with another line ("VideoBrowse") in the function fixConfigFilebrowsers() to the file Ivory\CKEditorBundle\Templating\CKEditorHelper.php, but it's not a good practices.

Have you got another solution for me ? Thank you for advance.

egeloen commented 8 years ago

If there is a filebrowser*Browser parameter not supported (Video in your case), we should support it. Is filebrowserVideoUrl built-in in CKEditor? When looking http://docs.ckeditor.com/#!/api/CKEDITOR.config I can't find it so why would yoou introduce a parameter not supported by CKEditor?

raphaelriehl commented 8 years ago

I use this plugin who integrate this route name. With CKEditor, it's possible to use custom filebrowser route name called by a custom plugin like video plugin. I don't want you integrate directly this filebrowser route name (filebrowserVideoBrowseRoute), i will like a method to custom $keys properly. (Sorry for my bad english, i hope my explanations are correct and understandable...)

egeloen commented 8 years ago

I understand your point and the use case but now, we need to figure out how to make it possible as right now it is not.

raphaelriehl commented 8 years ago

To complete my answer, ckeditor support this solution here : http://docs.ckeditor.com/#!/guide/dev_file_manager_configuration-section-adding-file-manager-scripts-for-selected-dialog-windows

egeloen commented 8 years ago

Yeah, so basically a simple extension point in the config should be enought in order to configure extra keys. Would you be interested about creating a PR for that?

egeloen commented 8 years ago

For the record, I'm working on it so there should be something available soon :)

egeloen commented 8 years ago

@raphaelriehl Your issue has been fixed in the referenced PR and is part of the new release.

raphaelriehl commented 8 years ago

Great ! Thanks for your job and your reactivity. :)

edit : it's work.