{"id":19036058,"date":"2026-10-04T09:00:10","date_gmt":"2026-10-04T09:00:10","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/problem-with-translation-files-3\/"},"modified":"2026-10-04T09:00:10","modified_gmt":"2026-10-04T09:00:10","slug":"problem-with-translation-files-3","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/problem-with-translation-files-3\/","title":{"rendered":"Problem with translation files"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Hello.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">I&#8217;m testing <strong>ERP 1.17.10<\/strong> on <strong>WordPress 7.1.2<\/strong> and the translation files generated by <strong>translate.wordpress.org<\/strong> (I tried with <strong>Spanish<\/strong>) and I noticed the following.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The <strong>&#8220;Accounting&#8221;<\/strong>, <strong>&#8220;Create Invoice&#8221;<\/strong> and <strong>&#8220;Settings&#8221;<\/strong> screens are not displayed and the following errors are reported in the browser console:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>For <strong>\"Accounting\"<\/strong>:<br \/><br \/>&#091;Error] SyntaxError: JSON Parse error: Unrecognized token '\\'<br \/>\tparse (admin.php:762)<br \/>\tCodice globale (admin.php:762)<br \/><br \/>&#091;Error] ReferenceError: Can't find variable: erpAcct<br \/>\t798 (bootstrap.js:1:73282)<br \/>\to (vendor.js:1:417)<br \/>\t797 (bootstrap.js:1:71767)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (vendor.js:1:288)<br \/>\tCodice globale (bootstrap.js:1)<br \/><br \/>&#091;Error] ReferenceError: Can't find variable: __<br \/>\t(funzione anonima) (admin.js:1:3918)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (admin.js:1:467)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (admin.js:1:168955)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (admin.js:1:478946)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (admin.js:1:470554)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (admin.js:1:383639)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (vendor.js:1:288)<br \/>\tCodice globale (admin.js:1)<br \/><br \/>For <strong>\"Settings\"<\/strong>:<br \/><br \/>&#091;Error] SyntaxError: JSON Parse error: Unrecognized token '\\'<br \/>\tparse (admin.php:18)<br \/>\tCodice globale (admin.php:18)<br \/><br \/>&#091;Error] SyntaxError: JSON Parse error: Unrecognized token '\\'<br \/>\tparse (admin.php:768)<br \/>\tCodice globale (admin.php:768)<br \/><br \/>&#091;Error] ReferenceError: Can't find variable: erpLocale<br \/>\t(funzione anonima) (i18n.js:821:90)<br \/>\t__webpack_require__ (i18n.js:20)<br \/>\t(funzione anonima) (i18n.js:63)<br \/>\tCodice globale (i18n.js:64)<br \/><br \/>&#091;Error] ReferenceError: Can't find variable: erpSettings<br \/>\t348 (erp-settings-bootstrap.js:1:19171)<br \/>\to (vendor.js:1:417)<br \/>\t347 (erp-settings-bootstrap.js:1:17774)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (vendor.js:1:288)<br \/>\tCodice globale (erp-settings-bootstrap.js:1)<br \/><br \/>&#091;Error] ReferenceError: Can't find variable: __<br \/>\t(funzione anonima) (erp-settings.js:1:4275)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:258)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:6682)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:997)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:4522)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:122943)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:180747)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:178632)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (erp-settings.js:1:147888)<br \/>\to (vendor.js:1:417)<br \/>\t(funzione anonima) (vendor.js:1:288)<br \/>\tCodice globale (erp-settings.js:1)<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">At the moment, the only solution that seems to work is to replace the <code>script<\/code> contained in the <code>function erp_accounting_page()<\/code> in the file <strong>\/modules\/accounting\/includes\/Classes\/Admin.php<\/strong> with this command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>window.erpAcct = {};<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">and the <code>script<\/code> contained in the file <strong>\/includes\/Settings\/views\/settings.php<\/strong> with this command:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>window.erpSettings = {};<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Thanks.<\/p>\n","protected":false},"template":"","class_list":["post-19036058","topic","type-topic","status-publish","hentry","topic-tag-localization","topic-tag-strings"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/19036058","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/19036058\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=19036058"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}