Closed bobbyworx closed 9 years ago
No idea. Do you get any errors in the web console?
When you say 'disappear', do you mean the entire editor disappears, and you get a regular textarea?
Disappears as in no field is displayed, not event a regular text field.. I am using tinymce-rails (4.1.3)
Hi, For disappearing the tinymce, there would be several reasons, for example, mistype, not installed the plugin properly or forget to remove the plugin after uninstalling, @bobbyworx in your case.., you are using third latest version of tinymce, for this version.. no need to execute this code.. tinyMCE.init({ selector: "textarea.tinymce", menubar : false, theme : "modern", plugins: "uploadimage" });``` by the way where did you mentioned this code ?? in your application.js ?? have you created tinymce.yml file in your "config" directory ?? if you have created tinymce.yml then no need to mention the above code in application.js file., Please check the plugins are correctly mention in the tinymce.yml as well as in the above code..!!
okay, I created a tinymce.yml file under config directory with the following code:
theme: "modern" toolbar1: bold italic | link uploadimage | undo redo | fontselect | forecolor | code | plugins:
view:
<%= f.text_area :offer_greeting, :value => offer_settings(@offer, :offer_greeting), :class => "tinymce", :rows => 4, :cols => 120 %>
Problem is now, tinymce does not load at all. I am seeing only the default text_area.
On Wed, Oct 1, 2014 at 6:09 PM, Rasool.SB notifications@github.com wrote:
Hi, For disappearing the tinymce, there would be several reasons, for example, mistype, not installed the plugin properly or forget to remove the plugin after uninstalling, @bobbyworx https://github.com/bobbyworx in your case.., you are using third latest version of tinymce, for this version.. no need to execute this code.. tinyMCE.init({ selector: "textarea.tinymce", menubar : false, theme : "modern", plugins: "uploadimage" });``` by the way where did you mentioned this code ?? in your application.js ?? have you created tinymce.yml file in your "config" directory ?? if you have created tinymce.yml then no need to mention the above code in application.js file., Please check the plugins are correctly mention in the tinymce.yml as well as in the above code..!!
— Reply to this email directly or view it on GitHub https://github.com/PerfectlyNormal/tinymce-rails-imageupload/issues/62#issuecomment-57479305 .
Bogdan Popa
<textarea class="tinymce" cols="120" id="offer_offer_greeting" name="offer[offer_greeting]" rows="4">
this shows on inspecting the text area
On Thu, Oct 2, 2014 at 10:13 AM, Bogdan Popa bogdan.popa.a@gmail.com wrote:
okay, I created a tinymce.yml file under config directory with the following code:
theme: "modern" toolbar1: bold italic | link uploadimage | undo redo | fontselect | forecolor | code | plugins:
- uploadimage
view:
<%= f.text_area :offer_greeting, :value => offer_settings(@offer, :offer_greeting), :class => "tinymce", :rows => 4, :cols => 120 %>
Problem is now, tinymce does not load at all. I am seeing only the default text_area.
On Wed, Oct 1, 2014 at 6:09 PM, Rasool.SB notifications@github.com wrote:
Hi, For disappearing the tinymce, there would be several reasons, for example, mistype, not installed the plugin properly or forget to remove the plugin after uninstalling, @bobbyworx https://github.com/bobbyworx in your case.., you are using third latest version of tinymce, for this version.. no need to execute this code.. tinyMCE.init({ selector: "textarea.tinymce", menubar : false, theme : "modern", plugins: "uploadimage" });``` by the way where did you mentioned this code ?? in your application.js ?? have you created tinymce.yml file in your "config" directory ?? if you have created tinymce.yml then no need to mention the above code in application.js file., Please check the plugins are correctly mention in the tinymce.yml as well as in the above code..!!
— Reply to this email directly or view it on GitHub https://github.com/PerfectlyNormal/tinymce-rails-imageupload/issues/62#issuecomment-57479305 .
Bogdan Popa
Bogdan Popa
Are you using Chrome? If so, what does the Console say? (View -> Developer -> JavaScript Console)
Also, does it work with the same configuration, but without uploadimage
in the plugin list or in the toolbar?
no, it does not.. I get 304 not modified from the console. Also, if it helps, this is how my partial looks like:
<%= tinymce_assets %>
...
<%= f.text_area :offer_greeting, :value => offer_settings(@offer, :offer_greeting), :class => "tinymce", :rows => 4, :cols => 120 %></br>
...
<% tinymce %>
Then I suggest you look at the documentation for TinyMCE and/or tinymce-rails, and get a working setup there before you try using this plugin.
I'm sorry, but I don't have time for hand-holding you through the installation and configuration of TinyMCE.
sorry, it does with this configuration:
toolbar:
- styleselect | bold italic | undo redo
- image | link
plugins:
- image
- link
only when I specify imageupload, it completely disappears.
If you can create a small demo app where this happens and upload somewhere, or send to me (perchr@northblue.org), I'll take a quick look at it.
okay, sounds good.
I've created the demo app, I'll send it to you any minute now, but maybe this error would help you:
ActionController::RoutingError (No route matches [GET] "/assets/tinymce/plugins/imageupload/plugin.js")
… imageupload/plugin.js
? Should be uploadimage/plugin.js
.
Other than that, might be related to the asset pipeline troubles
config.assets.precompile += %w( tinymce/plugins/uploadimage/plugin.js tinymce/plugins/uploadimage/langs/ro.js )
ok so I have this in my app.rb file but I get the same error. How can I specify the precompilation under public directory(as you mention in the docs)?
The point of using public
is to avoid involving the asset pipeline at all, which means no precompilation. The asset pipeline won't touch anything there, and since TinyMCE doesn't understand/use the pipeline, involving it doesn't make any difference anyways.
A possible issue if you're using Rails 4 is that it doesn't generate non-digested versions of the assets, so you only get tinymce/plugins/uploadimage/plugin-<digest>.js
, which TinyMCE won't find.
You could try by adding the gem non-stupid-digest-assets and see if that helps.
ok it shows now! thanks!
Got a bad response from the server
Is the error I got when uploading a picture but I guess there are issues related to this error already
fixed it. thanks for being so responsive!
Glad to hear you got it working.
Hi, my tinymce editor seems to disappear with this setup. What am I doing wrong?