I have a modx site that outputs some dates on a bunch of different pages in both English and French - it worked fine but now the owner is reporting French dates showing 'funny characters'
The database, modx and page are all using UTF8 encoding, the date value (publishedon) is stored as a unix time in the data base and is called like this:
[[+publishedon:strtotime:date=`%B %e, %Y`]]
Which from my understanding is just using the php strtotime function, however on the French pages the date shows up as:
d�cembre 18, 2018
So the Locale functions are working but not the character set, NOW immediately fog that date is some copy from the database:
"Le 18 décembre"
Using the correct characters, so we can see the encoding for the page is correct, but the function appears to be not using the correct character encoding!?
Modx has not been updated.
Does anyone know what might be going on here and how to set the corect encoding for the output?
UPDATED INFORMATION:
- there are 2 web contexts defined, English and French. Each has a locale defines as en_EN & fr_FR respectively
- the modx_charset is UTF-8 set in the system settings
- use_multibyte is enabled in the system settings an mbstring is installed & enabled on the server.
- modx version is 2.6.5