In the AddThis class file (AddThis.php) the function private function getAttributeTitle($entity) (line 391) uses the php function htmlentities to return the text that is shared.
When using accents in text such as "cuál" this function returns "cuál" which is wrong.
Please change this to the proper php function which is htmlspecialchars and returns the text as intended.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | addthis-fixed_unicode_chars_appearing_as_html_entities-2677066-4.patch | 1.08 KB | gisle |
Comments
Comment #2
jucedogi commentedComment #3
gisleThis happens to me as well:
When sharing link to Nodes on Facebook via "AddThis", Unicode characters in the title (but not in the body) are shown as HTML-entities, as can be seen here: https://www.facebook.com/kjemisk/posts/940597326028362 and in the screen shot below:
If you add the link to your Facebook wall directly (not via "AddThis"), Unicode is displayed correctly, see https://www.facebook.com/gisle.hannemyr/posts/10153301934546227.
Comment #4
gisleHere is a patch for this problem. Please review.
Comment #5
gisleI'll review it myself.
Thanks, jucedogi - it works!
Comment #6
gisleThis is actually a duplicate of #2644044: Warning htmlspecialchars - which have now been committed.