This thread is resolved. Here is a description of the problem and solution.
Problem:
WP-KaTeX plugin - backward slashes in [latex] shortcodes are removed in the translation.
Solution:
This issue is fixed with the current version of WPML version 4.2.8.
0% of people find this useful.
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
Tagged: Compatibility
Related documentation:
This topic contains 18 replies, has 3 voices.
Last updated by Itamar 2 weeks ago.
Assigned support staff: Itamar.
Author | Posts |
---|---|
July 21, 2019 at 8:29 am #4251663 | |
amielR |
I am trying to: translate hidden link Link to a page where the issue can be seen: hidden link I expected to see: equations like on the original page: hidden link Instead, I got: symbol / removed from all latex code and the equations are all wrong |
July 21, 2019 at 1:46 pm #4252335 | |
Itamar Supporter
Languages: English (English ) Hebrew (עברית ) Timezone: Asia/Jerusalem (GMT+02:00) |
Hi. Is this the plugin (WP-Katex) that you are using? If I understand correctly the problem is on the English page which is a translation of the Hebrew page. I'm not sure where I can see the problem of the missing forward-slash (/) symbol. Thanks, |
July 22, 2019 at 4:44 am #4253873 | |
amielR |
Hi Itamar! Yes, this is the plugin I am using - https://wordpress.org/plugins/wp-katex/ is it possible to ignore latex tags on translation? |
July 22, 2019 at 8:16 am #4254779 | |
Itamar Supporter
Languages: English (English ) Hebrew (עברית ) Timezone: Asia/Jerusalem (GMT+02:00) |
Hi. It seems that this is a compatibility issue with the WP-KaTeX plugin. This plugin is not officially compatible with WPML. You can check the full list of our compatible plugins here. The way to handle compatibility issues with new plugins is to replicate the issue on a clean WordPress installation. After replicating this issue on a clean installation, I'll be able to consult and escalated, if needed, the issue to our compatibility team. For this, I created a test website with a clean WordPress install. You can access it through this link: When done, please let me know what the results and where I can see them are. Thanks, |
July 23, 2019 at 12:53 pm #4266051 | |
amielR |
latex tags come at the beginning and the end of every math equation and it looks like that on the backend of every post: [latex display="true"]y=\frac{x}{2}+3, x=2-y^2[/latex] and it looks like the attached image on the frontend. i also did what you asked but i gor an error message trying to configure wpml as it is configured on my site |
July 23, 2019 at 12:59 pm #4266151 | |
amielR |
i chose the classic wpml editor and made the english version just to see if the latex is working and it is not. is it possible to ignore latex tags and the content between them as they are? |
July 23, 2019 at 5:18 pm #4268383 | |
Itamar Supporter
Languages: English (English ) Hebrew (עברית ) Timezone: Asia/Jerusalem (GMT+02:00) |
Hi and thanks for trying my suggestions. The issue indeed seems to be the removal of the backward slash (\) in the Translation Editor. Regards, |
July 25, 2019 at 9:32 am #4281323 | |
amielR |
all backward slashed were removed. not only before 'frac'. |
July 25, 2019 at 1:52 pm #4283819 | |
Itamar Supporter
Languages: English (English ) Hebrew (עברית ) Timezone: Asia/Jerusalem (GMT+02:00) |
Thanks. I've now escalated this issue to our compatibility team and they will try to find a fix for this issue. I'll keep you updated here with any news regarding this issue. Thank you for your patience. |
July 25, 2019 at 4:31 pm #4285175 | |
amielR |
Thanks! [latex display="true"] DO NOT CHANGE [/latex] |
July 25, 2019 at 4:37 pm #4285193 | |
amielR |
because there are also problems with { and } and other signs |
July 28, 2019 at 12:21 pm #4295475 | |
Itamar Supporter
Languages: English (English ) Hebrew (עברית ) Timezone: Asia/Jerusalem (GMT+02:00) |
Thanks. I've sent this additional information to our compatibility team. Best Regards, |
July 29, 2019 at 2:40 pm #4300971 | |
amielR |
please let me know the estimated time for fixing this issue. |
July 30, 2019 at 1:37 pm #4308095 | |
Itamar Supporter
Languages: English (English ) Hebrew (עברית ) Timezone: Asia/Jerusalem (GMT+02:00) |
Hi, Amiel. Our second tier supporter came back to me regarding this issue. It seems that the issue of the backslash that is being removed in the Translation Editor is known to us and is escalated to our developers. The issue will be addressed in future versions of WPML. I have no ETA for when it will be ready. Fortunately, our has a workaround for this issue. Here is what you need to do. When translating the posts that contain the [latex] shortcode with a backslash (\) add another backslash in the translation side in the Translation Editor. For example, like so: [latex display="true"]y=\\frac{x}{2}+3, x=2-y^2[/latex] This solves the problem on the front-end. Please note that if you update the post and then the translation, you would need to add a double backslash (\\) again. Thanks, |
August 13, 2019 at 3:04 pm #4389077 | |
Itamar Supporter
Languages: English (English ) Hebrew (עברית ) Timezone: Asia/Jerusalem (GMT+02:00) |
Changing status to Escalated to developers. |