Home › Forums › Ticket Products › Event Tickets Plus › Event Tickets Plus: Cyrillic text in tickets email.
- This topic has 9 replies, 2 voices, and was last updated 9 years, 1 month ago by
sergey.
-
AuthorPosts
-
March 16, 2017 at 3:30 am #1254978
sergey
ParticipantIf I edit ticket email template with some Russian text – it is ignored. How can I workaround that?
March 17, 2017 at 2:39 pm #1256088Andras
KeymasterHi Sergey,
Thanks for reaching out! Awesome question.
Try checking the encoding of the file. I believe if it’s encoding is ANSI, then you will not get the special characters to show. If you set it to UTF-8, then they might come through.
Give it a try and let me know if that works.
Cheers,
AndrasMarch 17, 2017 at 2:56 pm #1256095sergey
ParticipantThanks for reply.
How can I change/set encoding for the file? (I guess you mean email.php template file).I see this in existing header of template file(I did not change it):
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd”>
<html xmlns=”http://www.w3.org/1999/xhtml”>
<head>
<meta http-equiv=”Content-Type” content=”text/html;charset=UTF-8″ />
<title><?php esc_html_e( ‘Your tickets’, ‘event-tickets’ ); ?></title>Does it mean that encoding is set to utf-8 or I need to make additional settings somewhere?
-
This reply was modified 9 years, 1 month ago by
sergey.
March 20, 2017 at 1:42 pm #1256865Andras
KeymasterHi Sergey,
I’m sorry I wasn’t clear enough before. The HTML encoding didn’t even come to my mind. :blush:
I usually use Notepad++ for editing files. In that there is an “Encoding” menu where I can change the type of file encoding.
If you use the noral notepad on Windows, then you can do “Save as…” and choose the encoding next to the save button.
In the editor “Atom” you can go to the Edit menu and there you have an option to “Choose encoding” or just press Ctrl + Shift + U.
Does this help fix it?
Cheers,
AndrasMarch 20, 2017 at 3:04 pm #1256913sergey
ParticipantAndras, problem is that ANY cyrillic text in in tickets email is completely ignored.
All other templates (woocomerce and other addons) are ok with cyrillic text.
But tickets email template – not.And this is because this line in template (that you provide) contains error:
<meta http-equiv=”Content-Type” content=”text/html;charset=UTF-8″ />I fixed this error and cyrillic text went back.
Solved.
Please update template with correct line in futute releases.March 21, 2017 at 2:45 pm #1257609Andras
KeymasterHi Sergey,
That’s a great find. Could you point out where exactly the error is? I don’t see a difference between our code and what you pasted in. That would be very helpful and much appreciated.
Thanks,
AndrasMarch 21, 2017 at 10:17 pm #1257818sergey
Participantthis line:
<meta http-equiv=”Content-Type” content=”text/html;charset=UTF-8″ />
needs to be corrected to:
<meta http-equiv=”Content-Type” content=”text/html” charset=”UTF-8″ />March 22, 2017 at 8:42 am #1258051Andras
KeymasterThanks for sharing that, Sergey!
However, our code is proper, as the content attribute needs to have the value just like we have it, “text/html;charset=UTF-8”.
You can check that also here, for example: https://www.w3schools.com/tags/att_meta_http_equiv.asp
Or here: https://www.w3.org/wiki/HTML/Elements/meta#Example_A
The correction you suggested is almost HTML5 markup, which should be preceded by
<!DOCTYPE html>Seemingly the encoding / encoding declaration doesn’t work for you somehow. What you can do is to create a template override for the email.
Basically copy the wp-content\plugins\event-tickets\src\views\tickets\email.php file to
wp-content/[your-theme]/tribe-events/tickets/email.php and modify it according to your needs.
I hope this helps.
Cheers,
AndrasApril 13, 2017 at 9:35 am #1269534Support Droid
KeymasterHey there! This thread has been pretty quiet for the last three weeks, so we’re going to go ahead and close it to avoid confusion with other topics. If you’re still looking for help with this, please do open a new thread, reference this one and we’d be more than happy to continue the conversation over there.
Thanks so much!
The Events Calendar Support Team -
This reply was modified 9 years, 1 month ago by
-
AuthorPosts
- The topic ‘Event Tickets Plus: Cyrillic text in tickets email.’ is closed to new replies.
