Using IMCE to add a file with spaces and dashes in the filename, the url in the editor window looks like 11-07-11%20-%2011-11-11%20Menu%20%28Read-Only%29.pdf - but when I save and click the link, I get a 404 and the url shows 11-07-11%2520-%252011-11-11%2520Menu%2520%2528Read-Only%2529.pdf

CommentFileSizeAuthor
#2 2011-11-09_1803.png8.47 KBkruser

Comments

twod’s picture

http://www.w3schools.com/TAGS/ref_urlencode.asp is nice to have in these cases.
When you say "the url in the editor window", do you mean what's inserted into CKEditor's URL field in its image dialog?
That is entirely controlled by IMCE and the bridge plugin so maybe this should be moved to IMCE Wysiwyg brige's queue?

If you disable the editor after adding the link and copy/paste the URL from the source in the browser, is it correct?

kruser’s picture

StatusFileSize
new8.47 KB

It seems to come in okay from imce - see the screenshot with the editor disabled. Upon saving without Wysiwyg enabled, the file link is displayed okay.

twod’s picture

Hmm, if you toggle the editor on and off again after adding the image and disabling it, is it still ok?
If so, there's a problem when detaching the editor on the submit event (which should currently be done the same way as when clicking "Disable rich-text".

If you save the node, edit and disable the editor, is it still ok?
If so, the problem is with the text format/filter configuration. The URL is changed by one or more filters before being displayed, but the URL stored in the database is correct. Try disabling all filters in the format you're using and see if the URL is still incorrect when rendered.

kruser’s picture

Project: Wysiwyg » CKEditor Link
Component: Editor - CKEditor » Code

Thanks for the tip on disabling filters, I found that it's the ckeditor_link module's "CKEditor Link Filter" causing the issue. After I disabled it the link worked fine.

anrikun’s picture

Status: Active » Closed (duplicate)

This is a duplicate of #1308398: Double encoding of links to files.
This bug should be fixed in last dev.
Please try it and confirm that it works so that I make a new official release.