[Name,fallback=] doesn't work if fallback is Unicode string
Hello,
I am sending newletters in Russian.
The template
[Name,fallback=]
doesn't work if I specify non-Latin (Unicode, specifically) string as fallback. The resulting template is simply left as is.
This is extremely inconvenient and I would appreciate fixing this behaviour. I can't use Latin-based fallback strings, they will look weird from recipients' viewpoint.
Example of Russian template tried
[Name,fallback=подписчик]
(using Russian for 'subscriber')
Thanks.
This discussion has been closed.
Comments
I'll look into that. Thanks.
This happens because sendy uses str_replace to replace tags to fallbacks, and this function does not work properly with multibyte strings.
Possible solution: migrate str_replace with preg_replace since there is no multibyte version of str_replace function, and preg_replace is the fastest workaround here in terms of performance.
P.S. I believe there are also problems when a user specifies a multibyte value for the custom field.
I am experiencing this issue as well. Is there a solution to it?
Can someone pls HELP. When i subscribe through gravity forms, email is captured but not the name. WHY?
The Russian letters in fallback is still ignored.
Any news on this issue?
However if the value in additional field is in Russian it is substituted.
Moreover the additional filed is not substituted if its name contains Russian letters.
Same problem with hungarian letters.
Do you have any plans for fixing this? Turns out, that we are unable to use the core functions for Russian language.
Same problem with Vietnamese. Do you have any plan to fix?
This is now fixed in the latest version of Sendy (v2.1.1) → https://sendy.co/get-updated#211