Opened 12 years ago

Last modified 10 years ago

#678 confirmed Bug

E-mail Link dialog

Reported by: deadmoroz@… Owned by:
Priority: Normal Milestone:
Component: General Version:
Keywords: SF Cc: geirhelge@…, deadmoroz@…

Description

The bug appears when editing an e-mail link that contains non-latin characters within its subject or body and document's charset is different from utf-8.

oParser.CreateEMailUri method in fck_link.js escapes non-latin characters from utf-8 charset, so the url when passed into the document remains utf-8 encoded.


Moved from SF:
http://sourceforge.net/tracker/index.php?func=detail&aid=1325829&group_id=75348&atid=543653

Change History (5)

comment:1 Changed 12 years ago by Martin Kou

Reporter: changed from Martin Kou to deadmoroz@…

comment:2 Changed 12 years ago by Martin Kou

Cc: Frederico Caldeira Knabben geirhelge@… deadmoroz@… added

The problem is that escape() escapes the chars using the page encode.

I tried to find out something for 2 hours with no success. Maybe something with the RFC822... but nothing for now. More investigation is needed. Let us know if anyone has better results.


Moved from SF. Original poster: fredck

Did anyone take a closer look at this problem?

I've been googling all day and tried different solutions, however, none works in all browsers/mail clients.

*/editor/dialog/fck_link/fck_link.js* The function oParser.CreateEMailUri() use the JS function escape() on the subject and the body. Necessary to escape any special characters in the or body. It seems like the escape() function only works for ASCII characters. Found some posts about it here: http://www.compoundtheory.com/?action=displayPost&ID=40 http://www.kanolife.com/escape/2006/03/escape-and-unescape-javascript.html

encodeURIComponent() works when using Thunderbird, with both MS IE and Firefox. I've been trying to find somethings that work with MS Outlook, but nothing so far.


Moved from SF. Original poster: geirhelge

The document that is being edited and the page that contains FCKeditor embedded has windows-1251 charset.

Make some text selection, go to 'Insert/Edit link' dialog. Than choose 'E-mail' as link type and type sometnihg, let's say in russian in 'Message Subject' or/and 'Message Body' fields.

After the link is created, all non-ASCII charters are replased by

%uxxxx-kind strings, but when clicking the composed link,

'Subject' and 'Body' fragments that are passed into E-mail client are "broken" and look like □41C□430□43C... and so on.


Moved from SF. Original poster: deadmoroz

Please provide us the steps to reproduce it.


Moved from SF. Original poster: fredck

comment:3 Changed 12 years ago by Martin Kou

  1. Load sample01.php into IE.
  2. Choose the "Western European" encoding by the View -> Encoding menu.
  3. Change the href attribute of the "FCKeditor" link in the editor window to "mailto:測試@…" (the two characters before @ are Chinese characters)
  4. Press "Submit"

Note in the HTML output, the Chinese characters are turned into "測試", which is not right.

I think the hex encode and decode functions that I wrote and then deleted from the trunk for #268 could be used to get around this problem. Perhaps we should investigate this in 2.6 development?

comment:4 Changed 12 years ago by Martin Kou

Keywords: Confirmed added

comment:5 Changed 11 years ago by Frederico Caldeira Knabben

Cc: Frederico Caldeira Knabben removed

There are some comments in the Forums about it: http://www.fckeditor.net/forums/viewtopic.php?f=6&t=9977#p26260

Note: See TracTickets for help on using tickets.
© 2003 – 2019 CKSource – Frederico Knabben. All rights reserved. | Terms of use | Privacy policy