My install is Drupal 6.3 + FCKeditor 2.6.3 and 6.x 1.3 beta2 + IMCE

(I also tried 2.6.1 and 2.6.2 but it did not resolve the problem)

I am trying to add a thumbnail to my node that links to a bigger picture. I use IMCE to browse the server, select the thumbnail, and send the URL to FCKeditor. That part works.

Then I click "Link", choose the bigger picture, "send to FCKeditor", and nothing. It simply refuses to transfer the URL.

Both my 6.3 sites exhibit this problem. 5.x works fine.

Files: 
CommentFileSizeAuthor
#4 imce_set_app.js_.patch1.86 KBwwalc
#4 fckeditor.module.patch1.14 KBwwalc

Comments

I, too, am having a similar problem. Seems that it is not connecting with image toolkit; you set the size of the image and that's it.

Anyone have any solutions to this?

gg

I right click the image I want to link to and "Copy image location...", then paste.

It works around the bug, but is not a real solution of course.

The cause is quite technical: The field name of the normal link dialog is called txtUrl. The field name of the link field is txtLnkUrl and at the same time the field for the url for the image is called txtUrl. It is not possible to give separate field browser urls for the normal link dialog (which requires txtUrl) and the link tab in the image dialog (which requires txtLnkUrl).
The built-in filebrowser uses JavaScript interaction instead of html id's to fill the values. At this moment I do not see a solution unless FCKeditor or IMCE is changed.
A work around would be to close the image dialog and use the link dialog to enter a link.

Assigned:Unassigned» wwalc
Status:Active» Needs review
StatusFileSize
new1.14 KB
new1.86 KB

I had problems with internet connection in the middle when I was writing this, so sorry for repeating after Jorrit.

In IMCE 6.x there is a nice and easy way to open it and assign an ID of element in FCKeditor that should be updated (?q=imce&app=FCKEditor|url@txtUrl).

Unfortunately, in FCKeditor, LinkBrowserURL is used in connection with two ID's: txtUrl and txtLnkUrl and it depends on a context which one is chosen.
When "Insert/Edit Link" button is pressed, txtUrl is used, but when one press "Image" button and click on a "Link" tab, txtLnkUrl is used instead.

We need the following (I used shortened notation just to point out what's wrong):

"Insert/Edit Link"
FCKEdior.Config['LinkBrowserURL'] = "q=imce&app=FCKEditor|url@txtUrl;"

"Image"
FCKEdior.Config['ImageBrowserURL'] = "q=imce&app=FCKEditor|url@txtUrl;"
FCKEdior.Config['LinkBrowserURL'] = "q=imce&app=FCKEditor|url@txtLnkUrl;"

There is no easy way to fix this inside of FCKeditor (apart from changing the ID's that could break lots of plugins) also I don't think there is a chance for an easy hack for it. The only workaround could be done with a special plugin for FCKeditor that would replace the original fckeditor\editor\dialog\fck_image functionality (bad idea).

There is also a second option: change IMCE code a bit to accept more than one ID, so that we could assign:

FCKEdior.Config['LinkBrowserURL'] = ?q=imce&app=FCKEditor|url@txtLnkUrl,txtUrl

(use txtLnkUrl if it is available, otherwise try another ID: txtUrl)

It seems to solve the problem described here.

I'm attaching a patch (files from both modules must be patched), please take a look at it and let me know what you think of it.

As long as you make sure that txtUrl is not being used when you give txtUrl and txtLnkUrl it's fine, because the main image url field is also called txtUrl. But from the looks of it that is the case.

@Jorrit: exactly, that's why txtLnkUrl is on the first place in the patch above and we're exiting from a loop with a break statement when fileld from given list is found.
Without break statements in IMCE code, both fields would be updated in FCKeditor.

Added feature request to IMCE tracker: #301082: Support passing more than one ID in url@.

#315241: IMCE integration bug marked as duplicate.

Title:image will not linkIMCE integration issue (url@txtUrl/txtLnkUrl)

This is done on IMCE 6.x branch.
Sorry for the late patch.
#301082: Support passing more than one ID in url@

Status:Needs review» Patch (to be ported)

Awesome, thanks!
I'll correct the FCKeditor module as soon as the new IMCE module will be available for download (I cannot commit it sooner because earlier version of the IMCE module will not recognize the new format).

Subscribing. Thanks to you guys for these modules. Could you please specify which versions to use when this issue is fixed? I am assuming that it will be:

Drupal 6.10
FCKeditor 2.6.4 with 6.x-1.4
IMCE 6.x-1.2

Is that right?

Thanks.

I hope the patch will be applied soon :-)

Status:Patch (to be ported)» Fixed

Fixed in CVS.

Many thanks!

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.