Notifications
Clear all

[3.5] Special HTML characters being converted into "r" code

14 Posts
4 Users
0 Likes
21.6 K Views
(@azurite)
Posts: 209
Reputable Member
Topic starter
 

I use a number of "special" characters in my fics, such as Γ©, ellipses, and em-dashes. Due to certain sites restricting HTML, I usually use the num-code for these characters, e.g.

—

and the like. But I've been noticing that many of them get converted to codes like r30; or r04; whenever I preview or edit an added story of mine. I want to ensure I don't persistently have to go into the HTML of each chapter and test out possible fixes, e.g. change it from num-code to the standard HTML special-character syntax (because, again, some sites don't accept it, and I've found the num-code to be more universally recognized). I don't know if this is an eFic thing or a TinyMCE thing.

I've gone into the site settings section of the Admin Panel and added the num codes, but they get converted to their actual form-- that is, instead of displaying the code for an em-dash or an ellipsis, it shows the actual em-dash and ellipsis! I don't know if that means they will be "allowable" in text or not. It doesn't look that way, based on this chapter I recently uploaded (I uploaded it before I made the above changes in the site settings, but wouldn't allowing a new range of characters/tags mean they show up properly? Or no?):

http://drfa.seventh-star.net/viewstory.php?sid=1&chapter=27

This story I recently added, but for some reason, it's not showing up on the Recently Updated block. I was having the Fatal Error mention in previous posts, but I'm not sure if I fixed it, so please let me know if you can't access this chapter.

The help dialog on the site settings panel mentions TinyMCE stripping or "cleaning up" HTML, but I can't find any documentation in the plugin as to WHAT exactly it does or how you can modify what TinyMCE allows/refuses.

Help?

Thank you!

Archive: Dragonfayth
eFiction: 3.5.5/6
Latest Patch(es): Yes
bridged?: No
modified?: Yes
PHP: 7.4.25
MySQL: 5.7.32-35-log

 
Posted : 05/04/2009 10:35 pm
(@carissa)
Posts: 791
Member Moderator
 

Someone asked about this in the support forums, and she is not using TinyMCE so I don't think it has anything to do with that. Do you have a test account on your site? I want to look at it, but I'm not registered.

 
Posted : 07/04/2009 6:18 pm
(@azurite)
Posts: 209
Reputable Member
Topic starter
 

Yes; the username is Test Account and the password is t3st3r.

Archive: Dragonfayth
eFiction: 3.5.5/6
Latest Patch(es): Yes
bridged?: No
modified?: Yes
PHP: 7.4.25
MySQL: 5.7.32-35-log

 
Posted : 07/04/2009 6:21 pm
(@carissa)
Posts: 791
Member Moderator
 

I don't see the problem. What browser and operating system are you using?

 
Posted : 07/04/2009 6:24 pm
(@azurite)
Posts: 209
Reputable Member
Topic starter
 

Mac OS X 10.5.6, Firefox 3.0.8.

I may have fixed the problem inadvertently by adding the special character num codes to the Allowed Tags field, even though I wasn't sure if they counted as "tags," being that they're not enclosed in angle brackets. Furthermore, I don't know if adding them in that manner also allows the long-hand form of the characters, e.g.

…

to come through, not just the num-code version.

Archive: Dragonfayth
eFiction: 3.5.5/6
Latest Patch(es): Yes
bridged?: No
modified?: Yes
PHP: 7.4.25
MySQL: 5.7.32-35-log

 
Posted : 07/04/2009 7:00 pm
(@carissa)
Posts: 791
Member Moderator
 

Could you try uploading a new story as a test? I don't see the special characters at all when I view your source and I should be seeing them...Adding them to the allowed tags shouldn't work but maybe it did.

 
Posted : 08/04/2009 11:45 am
(@tammy)
Posts: 2577
Member Moderator
 

It won't work

striptags only works with HTML tags.

 
Posted : 08/04/2009 12:15 pm
(@azurite)
Posts: 209
Reputable Member
Topic starter
 

That's what I find totally weird. I didn't EXPECT it to work, since the special character num/long-form codes aren't really HTML, but they ended up getting converted in the HTML Allowable Tags box anyway, and then the chapter where they were appearing as crazy r30; and such codes seemed to look fine to me! But if it's only something visible with a chapter initially when it's uploaded or something, maybe I have nothing to worry about? I don't know, a huge majority of fics on my site use these characters, so is there any way to ensure that they'll always be left intact?

Archive: Dragonfayth
eFiction: 3.5.5/6
Latest Patch(es): Yes
bridged?: No
modified?: Yes
PHP: 7.4.25
MySQL: 5.7.32-35-log

 
Posted : 08/04/2009 5:17 pm
Jan_AQ
(@jan_aq)
Posts: 1300
Noble Member
 

Please check and see if this is an issue still with 3.5.1. Thank you.

Whoever said nothing is impossible never tried slamming a revolving door.

url: https://www.potionsandsnitches.org/fanfiction
php: 7.4.33 msql: 5.6.51-community GPL
efic version: 3.5.5 latest patches: yes
bridges: none mods: challenges, tracker, story end, beta, word

 
Posted : 24/04/2009 10:21 pm
(@tammy)
Posts: 2577
Member Moderator
 

How are you sending these special characters?  As HTML entities?  Or are you just cutting and pasting?  If the later it's probably a mismatch in the charset between what you're sending and what the database is storing. 

 
Posted : 20/06/2009 1:08 am
(@azurite)
Posts: 209
Reputable Member
Topic starter
 

Okay, so I checked before I updated my files with the latest SVN release, and after, and both times, the r-character issue doesn't appear to be happening again. That could be because I inputted those special HTML characters in the "Allowed Tags" field, or because at some point I did an internal find-replace that worked, but I'm not sure which (if either). Also, I was of the understanding that only bracketed HTML tags would work in the Allowed Tags field, not characters like

é

, which is how I was "sending" the characters, both in my text and in the Allowed Tags field. The actual text converts the characters properly, but when displaying what tags are allowed, it shows the code, rather than the resulting symbol.

For example, when I (an admin, and the owner of my story) go to modify my chapter, I see this:

Note: Allowed HTML tags are: <strong> <br> <em> <br /> <blockquote> <strike> <b> <i> <u> <center> <img> <a> <hr> <p> <ul> <li> <ol>&#151;&#8230;&#233;

I thought I had TinyMCE on and working (it displayed when I went to add a new News Item), so the tiny MCE box is checked, but I don't actually see any of the TinyMCE tools. I do see my story in HTML mode, but the special characters appear "normal" --that is, NOT in code.

I'm wondering if maybe this problem relates to the disappearing act my TinyMCE keeps trying to pull? I've tried updating it, checking my header.php file, double-checking that all the files in place...why would it show up for one part of the site but not another? Could it even be behind this weird processing of special characters?

Archive: Dragonfayth
eFiction: 3.5.5/6
Latest Patch(es): Yes
bridged?: No
modified?: Yes
PHP: 7.4.25
MySQL: 5.7.32-35-log

 
Posted : 28/06/2009 3:25 pm
(@tammy)
Posts: 2577
Member Moderator
 

It probably is tinyMCE.  tinyMCE does it's own cleanup of submitted code before sending.  I think you'll need a custom tinyMCE cofig that allows raw encoding.  Check the tinyMCE site.  Do it VERY carefully though as that's one way you can get hacked.

 
Posted : 07/07/2009 8:22 pm
Jan_AQ
(@jan_aq)
Posts: 1300
Noble Member
 

Any updates on this issue? πŸ™‚

Whoever said nothing is impossible never tried slamming a revolving door.

url: https://www.potionsandsnitches.org/fanfiction
php: 7.4.33 msql: 5.6.51-community GPL
efic version: 3.5.5 latest patches: yes
bridges: none mods: challenges, tracker, story end, beta, word

 
Posted : 23/11/2009 8:18 pm
Jan_AQ
(@jan_aq)
Posts: 1300
Noble Member
 

Someone please update as to whether or not this has been fixed (newest SVN files) by testing on their archive. Thank you!

Whoever said nothing is impossible never tried slamming a revolving door.

url: https://www.potionsandsnitches.org/fanfiction
php: 7.4.33 msql: 5.6.51-community GPL
efic version: 3.5.5 latest patches: yes
bridges: none mods: challenges, tracker, story end, beta, word

 
Posted : 04/10/2010 3:44 am
Share: