I have the Img Assist module installed, and it works correctly. Today I installed the TinyMCE module, and now the Img Assist module doesn't work correctly.
Here is what happens. I click on the Img Assist button to add a new image. I choose an image to add. It takes me through the usual steps (position, title, description, thumbnail or original size, etc..), but then I click the button to insert the Img Assist filtered code, it doesn't insert the code nor does the Img Assist pop-up window close. Therefore, I am unable to add an image using Img Assist while using TinyMCE at the same time.
Does anyone else have this same problem? Is there a setting I could change to make it work? Is there any known work-around for this issue?
Comments
Comment #1
nathanraft commentedI was just about to try the same thing and checked the bug list just to be sure and found this...
Did you try this from the Img Assist Install.txt?
-- TINYMCE PLUGIN INSTALLATION --
If you use the TinyMCE WYSIWYG editor, you need to install a plugin for Image
Assist.
* Move or copy the folder 'drupalimage' in the img_assist directory to
[sites/all]/modules/tinymce/tinymce/jscripts/tiny_mce/plugins/
Edit the file plugin_reg.php in the tinymce directory. It's located in:
[sites/all]/modules/tinymce/plugin_reg.php
Add the following lines anywhere above the 'return' statement:
Next, go to
Administer > Site configuration > TinyMCE
and enable the drupalimage plugin in your TinyMCE profile.
Comment #2
floretan commentedThe problem comes from some code in tinymce.module (line 176 in version 5.x-1.9), which is making a call to the unknown javascript method tinyMCE.getEditorId(). It seems that this part of the code has not been updated for changes in the tinymce plugin (3rd party, not the drupal module).
It seems that rather than using the getEditorId() method, we could just use tinyMCE.editors.edit-body (or whatever name the textfield has). The problem is that since this property has a dash in its name, it can't be used in the code. I'm not familiar enough with the tinyMCE javascript code to provide a solid solution, but I'll gladly help and commit a patch if somebody can point me in the right direction.
The getEditorId() method is also called in two other places in the drupal tinyMCE module, but it looks like a similar issue.
Comment #3
floretan commentedSee related issue in the img_assist issue queue: http://drupal.org/node/191418
Comment #4
aaron commentedI'm actually finding that function in the resulting js, in tiny_mce_gzip.php, at line 2166 when examining it in the source. (It's also in tiny_mce.js, although it's hard to read that function in the source w/o line breaks).
getEditorId : function(form_element) {var inst = this.getInstanceById(form_element);
if (!inst)
return null;
return inst.editorId;
}
Comment #5
aaron commentedAdditionally, when disabling the drupalimage button from the profile, the standard Image Assist icon still disappears from below the textarea when TinyMCE is enabled for a textarea.
Comment #6
aaron commentedFor that matter, the Image Assist icon still disappears with TinyMCE enabled even if I remove the drupalimage lines from plugin_reg.php.
Comment #7
a.angelo commentedHi all!
My installation: Win XP Pro SP2, Drupal 5.1
Browser: both Firefox 2.0 and IE 6
Months ago I installed Drupal 5.1, together with some modules activated. Additional modules installed are the following: i18n, image, image-gallery, image-import, img_assist, poormanscron.
All modules were OK.
After that I downloaded and installed TinyMCE following the suggested installation, but in no way I can see the link to the WYSIWYG editor.
TinyMCE was enabled for 'power user' profile an activated by default.
Today I attempted to upgrade to the new version:
- I deleted C:\drupal-5.1\sites\all\modules folder
- I downloaded tinymce-5.x-1.9.tar.gz and TinyMCE Version 2.1.3
- I copied tinymce folder (from tinymce-5.x-1.9.tar.gz) into sites\all\modules
- I copied tinymce folder (from tinymce_2_1_3.zip) into sites\all\modules\tinymce
- I review tinymce setting (that were unchanged)
but I still cannot see the link to work with TinyMCE.
- What can I check?
- Maybe a conflict with existing image_assist module?
Thanks!
Antonio
Comment #8
mupsi