Encoding in PM's changes symbols to questionmarks

Be sure to read and follow the guidelines for our forums.

Jan 18, 2021 9:24 am
I wanted to point out that in PM's certain symbols like apostrophes get changed into question marks, likely due to an encoding problem.
Jan 18, 2021 10:30 am
Did you write the PM from your phone? Because I have that issue but only from my phone not when I use an actual computer
Jan 18, 2021 4:42 pm
Hm... it shouldn't matter phone or computer realistically speaking, but I'll look into it.
Jan 18, 2021 11:34 pm
This happens often when copy/pasting from a pdf. It might be certain fonts are not recognized so the apostrophes are interpreted as the question mark.
Jan 19, 2021 1:26 am
Just for information, this happens on character sheets as well (at least Custom ones, not sure about others).
Jan 19, 2021 2:03 am
Yeah, I get this error when copying from an RTF (Mac TextEdit) into the site.
Jun 15, 2021 12:23 pm
I think it's the utf8_decode in api/functions.php line 75.

https://www.php.net/manual/en/function.utf8-decode.php

I notice it when I'm typing on a phone and it decides to use curly apostrophes.

Here's a test string to use in a message.

utf8_decode said "That’s a ‘bad’ character."
Jun 15, 2021 1:01 pm
Ah, that makes sense. The Mac Text Editor uses auto-correct to change " to ", for instance. (That is, straight quotes to "smart quotes.")
Last edited June 15, 2021 1:01 pm
Jun 15, 2021 1:24 pm
I'm not really sure what the idea is in that bit of code, so I'm going to leave it well alone for now. It's probably not there by accident.

Put it this way, I browsed @Keleth's check-in comments on that file...

https://i.imgur.com/m5lGSfm.png

...and I think it's a warning that here be dragons.

But it's not like people are going to stop using Apple devices any time soon. Perhaps if the code is going to sulk whenever it's given slightly unusual characters then we could at least replace smart quotes with straight quotes. Maybe?
Jun 15, 2021 1:52 pm
I experienced this problem but only with custom sheets not my D&D 5e ones it was on a LG G3 phone, and It was probably result of copying from a PDF.
OOC:
just wait until we have a user called UTF8 that's when the fun will start. :)
Jun 15, 2021 1:59 pm
KoldikSteelskin says:
I experienced this problem but only with custom sheets not my D&D 5e ones it was on a LG G3 phone, and It was probably result of copying from a PDF.
Yeah - it's not just messages. It's all over the shop.
KoldikSteelskin says:
just wait until we have a user called UTF8 that's when the fun will start. :)
That wasn't so much a "laugh out loud" as "cackle like a drain".

You do not have permission to post in this thread.