Project:IMCE
Version:6.x-1.2
Component:Code
Category:support request
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

IMCE was running fine with TinyMCE and broke down overnight and I cannot link anything that happened on the site to this error.

IMCE opens well from TinyMCE and I can click on the folder button but the expected buttons do no longer appear: upload, thulbnails, resize and send to TinyMCE buttons are missing. See the attached file to clarify what is meant.

Deinstalling and reinstalling of imce, imce_wysiwyg, wysiwyg, tinymce does not change anything.
Seems that something in the database has changed somewhere and breaks something.

Currently running
- drupal 6.9
- imce 6.x-1.2
- imce_wysiwyg bridge 6.x-1.0
- wysiwyg 6.x-1.1

AttachmentSize
imce_wysiwyg.jpg37.93 KB

Comments

#1

Did some further testing and switched to FCKeditor (without the imce_wysiwyg bridge) and exactly the same problem persists.

Conclusion: it has either something to do with IMCE itself or with some broken info in a database

#2

Category:bug report» support request
Priority:critical» normal

You should write down the steps to reproduce the bug and be sure before marking an issue as critical bug.

Could this be related to your theme?
Do you get any javascript errors on the page?

#3

I am having the same issue. The problem is somewhere in the theme. If I load up the default theme its all good.
It's throwing a java script error.

form.ajaxForm is not a function
[Break on this error] form.ajaxForm(imce.uploadSettings());//set ajax

on line 248 of imce.js which is

form.ajaxForm(imce.uploadSettings());//set ajax

UPDATE
We had a second version of query being added in the theme, this is what was causing the error.
...Now I have to figure out why we were loading a second jquery...

#4

ajaxForm is added by jquery form plugin whose path is misc/jquery.form.js
You should be sure that this file exists and loads in the page and also does not conflict with your jquery version.

#5

The problem as I described is not theme related. The problem is also present with the Garland theme.
No Javascript or other errors are flagged.

The error is persistant, so it is not possible to give a specific sequence of steps.

I just
- create a new page or edit an existing page
- the editor opens
- click the image button in the editor
- click the browser button
- the picture appears as attached under #1

For me the error is critical because IMCE is currently not useable at all for me.

#6

I'm experiencing identical behavior to that described by Marc, but only on select sites. I'll post back if I find the culprit.

#7

If you're missing the "send to TinyMCE" button, the culprit may be the "Secure Pages" module.

Secure Pages interferes with IMCE (If the imce window is running as https, then it cannot communicate with the window that TinyMCE is in)

Go here:
/admin/build/securepages

and add this line to the Ignore Pages: box.
*/imce*

Save, and be happy.

#8

We had this same issue recently using the latest version of IMCE. I noticed that in the IMCE popups, javascript files from our custom frontend theme were being loaded, even though we use the RootCandy admin theme on the backend. It seems as though IMCE should only load the current theme's javascript from the .info (RootCandy in this case), but perhaps there is something I am missing

I tracked down the conflicting file to be jQuery Tools, a library we used in our theme.

#9

subscribe for reference about conflict with securepages

#10

From the project page:

Known issues

  • IMCE may have problem working with Google Analytics and Secure pages modules. Just make sure to add imce* path to the exceptions list of these modules.
  • Simplemenu
  • Artisteer themes

Check if any of them apply to your case.

#11

I had a similar issue as other people noted. However, the buttons appear in Safari, but not in Firefox. It was working before and I'll try to go back and do a bit more debugging when I have time.

#12

I had trouble showing the "send to..." stuff with RootCandy as well. Ended up trying Themekey which resolved my problem. Technique was mentioned in this comment. (this was a reply to #8 above)

#13

Status:active» closed (fixed)

re-open against 6.x-2.x branch.

#14

If you're using the sections module, make sure to add "imce" to your list of pages that should be displayed by the admin theme. My problem existed because I'm using a separate jquery file for my site theme, so it was overriding misc/jquery.form.js .

#15

Having exactly the same problems that Marc Hoefman has been (or at least was) having. I've tried everything ufku has mentioned in this thread as well as thread #584952: Missing options in IMCE with Acrylic theme. I've reverted back to Garland to no avail, so I'm sure it's not theme related. I don't have any of the offending modules (Google Analytics / Secure pages) running, so the only thing I can think it might be is "safe mode restriction" on my server, which I doubt.

Thanks in advance for any help!

#16

I have had this issue and resolved it. All of the facts you guys are pointing out about what is loaded and stuff is really just confusing the issue.

Here is the issue that I have found. When IMCE is loaded it is loaded into an iFrame. This iFrame includes all of the CSS and JS that was on the original page in the head. This can cause a problem if the JS that you have on your site makes any assumptions about the content that is on the page.

For example. I had this line of code on my site: map_obj.map = new GMap2(document.getElementById("map-canvas"));

The 'map-canvas' WAS on the PAGE, but it was NOT in the IMCE iFrame. Because all the CSS and JS is loaded into the head of the iFrame, this line of code was attempting to run in the context of the iFrame. This was giving an error of "Uncaught TypeError: Cannot read property 'firstChild' of null" which was causing the options in IMCE not to load.

I was able to solve this by simply doing a test to make sure the element was on the page with something like: if ($("#map-canvas").length > 0) { addGMapToPage(); }

Basically, this problem is due to some JS file making an assumption that something is on the page (which it may be), but it is not on the page in the context of the IMCE iFrame.

I hope this helps someone...

nobody click here