I am trying to use TInyMCE. I want Image upload feature. So I am going to follow this tutorial: http://serenetechnologies.ca/using-dragonfly-to-upload-images-to-rails-with-tinymce/
When I used the CDN provided by TinyMCE. But when I use the following plugin as a gem https://github.com/PerfectlyNormal/tinymce-rails-imageupload
, it searches for it in the cdn and fails to find it. SO I thought of using a gem for tinymce.
So used tinymce-rails
gem. Then I copied the plugins advlist,autolink,lists,link,image,charmap,print,preview,anchor,searchreplace,visualblocks,code,fullscreen,insertdatetime,media,table,contextmenu,paste
to the assets/javascripts/tinymce/plugins folder.
I also copied the modern skin and theme to similar locations.
and I am invoking tinyMCE using:
tinyMCE.init({
"mode":"specific_textareas",
"selector": ".tinymce-editor",
'theme': 'modern',
"toolbar":"insertfile undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image uploadimage",
"plugins":"advlist,autolink,lists,link,image,charmap,print,preview,anchor,searchreplace,visualblocks,code,fullscreen,insertdatetime,media,table,contextmenu,paste,uploadimage",
"width":810,
"language":"en"
})
But I get the following error:
I dont know how to proceed
The tinymce plugin list (using tinymce4!) needs to look like this (with brackets)
plugins: [
"advlist autolink lists link image charmap print preview anchor",
"searchreplace visualblocks code fullscreen",
"insertdatetime media table contextmenu paste"
],