I've put together a number of sites in which I've opted for the TinyMCE editor. On my most recent, I thought it would be interesting to play with the FCKeditor. My preferred browser is Firefox, though I check things out in IE.

This evening I got an email from someone who said the hyperlink on an image in the recent site wasn't working. I checked it out, first in Firefox, and it worked fine. Then I tried it in IE8, and sure enough, the link didn't appear to do anything. Hmm. So I checked the code.

The image was contained in an input tag:
<a href="sites/default/files/prettypicture.jpg"><input type="image" ....

But the link worked fine in both browsers when I manually changed the code to:
<a href="sites/default/files/prettypicture.jpg"><img src="sites....

It took me a while to figure out that the input tag was being used by FCKeditor on its image button, whereas TinyMCE inserts an img tag.

It's a problem - I add hyperlinks to a lot of images.

Can I tell FCKeditor how to insert images?
Do I have to abandon FCKeditor because of this limitation?

Thanks.

Comments

WorldFallz’s picture

Not sure what the problem could be, but fckeditor/ckeditor works fine-- i've been using it for quite a while (both with the fckeditor and wysiwyg modules) and never came across this problem. Also, I doubt it could be a common problem or some of the other 57k+ users of it would have come across it as well.

ArthurC’s picture

Thanks for the quick reply. Agree with you that it can't be a common problem, but I'm not using anything unconventional. Would you post a link to an image with a hyperlink created with the FCKeditor? I'd like to try it, see what happens on my end. Then if the link doesn't work for me, I'll know it's something on the client end. If it works for me, then I can mine through the code and perhaps find an answer. If not a solution.

WorldFallz’s picture

Sorry-- my sites that use fckeditor are on an intranet behind a firewall. What about testing it out on the fckeditor demo sites? (http://ckeditor.com/demo and http://ckfinder.com/demo).

bsenftner’s picture

For your reference, every image on this site was inserted via FCKeditor:
http://www.usmnebc.org

ArthurC’s picture

Thank-you both for the information. I checked the sites. The source code that's been generated encloses images in Only local images are allowed. tags. The images in my webpages are enclosed in tags. I have no idea why. I built the site in Drupal 6.14 and used the WYSIWYG 6x-2.0 module and the FCKeditor 2.6.5 library.

The Image Button that pops up when I want to insert an image looks like this:
http://www.coalwatch.ca/sites/default/files/ImageButtonClip.jpg

The image is included in a tag and any anchor I put around it won't pop up in IE8, at least, and probably other IE versions.

I'm stuck. Don't know what to do otherwise than to abandon FCKeditor and go back to TinyMCE.

bsenftner’s picture

Arthur,

Your image upload dialog looks a bit different than what I get:
http://www.usmnebc.org/sites/www.usmnebc.org/files/image/imageUploadDial...

As you can see, I have a "browse" upload button on the "image info" tab, and rather than an "advanced" tab, I have an "upload" tab.

Seeing your image triggered my memory of a setup step I always do when installing a new version of FCKeditor...
Visit your admin/settings/fckeditor/edit/Advanced page and go to the bottom, and expand the "Advanced Options" collapsible section and make sure you have inside the "Custom javascript configuration:" settings this:

LinkDlgHideTarget = true ;
LinkDlgHideAdvanced = true ;
ImageDlgHideLink = true ;
ImageDlgHideAdvanced = true ;
FlashDlgHideAdvanced = true ;

Those settings are not default, but suggested in the text just below that text field. I remember before I had those settings in place, image markup was not being generated correctly...
I hope this does the trick for you!

Also, in my correctly working version, I only use the "Browse" button on the "image info" tab to generate an uploaded image - I never use the "upload" tab's functions because they don't work!

ArthurC’s picture

I don't have "admin/settings/fckeditor/edit/Advanced". Instead, I have "admin/settings/wsywig/fckeditor/profile/2/edit", and I can't find any "Advanced" option. I'm beginning to feel like I've installed software from the Twilight Zone. Any moment now, Rod Sterling is going to walk on stage and say ... "You're on Candid Camera!"

WorldFallz’s picture

That would be because you appear to be using the wysiwgy module, not the fckeditor module (there's 2 ways to use the fckeditor js). Maybe switch over to the fckeditor module.

ArthurC’s picture

Yes. Actually, I thought I was supposed to be using the WYSIWYG module with FCKeditor. Perhaps I was making a careless assumption because that is what has happened with TinyMCE, the editor I am more familiar with. But now that you point me to it, I see that FCKeditor comes with no admonition to use it with the WYSIWYG module. So I won't. I'll try the FCKeditor straight on, and will report back.