Hi All,
We have a landing page with weird, unexpected behavior: The character encoding in the form fields (for prefilled fields) is not correct, while it is OK in the rest of the LP. See:
I have been entering the form with my first name "Grégoire" correctly many times and it is correctly displayed in Marketo UI.
Any idea?
-Greg
Solved! Go to Solution.
This couldn't have helped, anyway. It's not an encoding problem but a decoding/transcoding problem at display time. As long as the data ended up in UTF8 within Marketo (which is actually independent of the form post encoding) it would still be pulled out wrong.
That is, the prob is specifically when UTF-8 stored strings are treated as if they were stored as 8859. Since the db only is going to use a single encoding per column, you'd still be storing UTF-8.
Many a hack is based on this same problem, btw.
This is 16-bit (UTF-16) JS strings being mistakenly treated as UTF-8, or UTF-8 being treated as ASCII/ISO-8859-1, then being htmlentities()-ed. I have to go to sleep but I'll respond more on it tomw.
Well, this is a giant bug. I could go on my blog with the usual "Here's a bug and how to fix it" post -- but actually, there's no fix, only a workaround, and I'd rather not advise it formally when really this needs to get fixed ASAP.
Here's how the bug happens:
So, bottom line, Justin Cooperman this is in need of a back-end fix.
Thx Sanford Whiteman for this!!
If we encode the page in ISO-8859-1, will this workaround/fix the bug?
-Greg
Hi all,
OK, I tried to set the meta charset the following way
<meta charset="ISO-8859-1">
But Marketo will only accept utf-8
-Greg
This couldn't have helped, anyway. It's not an encoding problem but a decoding/transcoding problem at display time. As long as the data ended up in UTF8 within Marketo (which is actually independent of the form post encoding) it would still be pulled out wrong.
That is, the prob is specifically when UTF-8 stored strings are treated as if they were stored as 8859. Since the db only is going to use a single encoding per column, you'd still be storing UTF-8.
Many a hack is based on this same problem, btw.
My name is Finder, Bug Finder
Hey Justin Cooperman if you can ack this and give an ETA, that would be handy. I'm dying to blog about it as it might entertain/educate readers -- but not if it's going to be fixed before I hit "Publish."
We already have a P1 bug open on this and it will be patched soon.
Justin
Hi Justin,
Thx.
Is it going to be released to all instances or do you need that we fill in a support ticket?
-Greg