Skip to main content
added 643 characters in body
Source Link

I can see the problem (I saw this myself recently), but I don't have a 100% answer. However, the solution is usually to rebuild your multilingual schema.

The problems stems from theThis problem in the first console error, "Unexpected Token". There's a JS file that gets createdis characterized by:

  • Multilingual mode is activated on your CiviCRM site.
  • Error in the browser console show files not found at a path with the word "undefined" in it.
  • Also, "DB Error: no such field" errors (though this can also be caused by missing extensions or failing to upgrade the database after upgrading the CiviCRM files).

Based on the fly from a PHP template (l10n.js). Something in your WP instance (a plugin perhaps?) is modifyingthese instructions, here's how you rebuild the output of multilingual schema:

From within CiviCRM (CiviCRM 5.1+ only):

  • Go to Support menu » Developer » API Explorer.
  • Set Entity to System and Action to rebuildmultilingualschema.
  • Press the Execute button.

From the command line (Civi 5.0.1 and earlier):

Drupal 7

l10n.jsdrush php-eval 'civicrm_initialize(); CRM_Core_I18n_Schema::rebuildMultilingualSchema(["en_US","fr_CA"], NULL);', causing a JavaScript error. In turn, that causes JS to stop running on the page and other errors occur.

If you click on the link in that line (it starts with Drupal 8

admin.drush php?page=CiviC-eval '\Drupal::service('civicrm')->initialize(); CRM_Core_I18n_Schema::rebuildMultilingualSchema(["en_US","fr_CA"], NULL);') then you'll see the modified file. Look for lines that appear to be added by a plugin. Hopefully you have a test site that you can compare with the same file to see the difference.

WordPress

wp eval 'civicrm_initialize(); CRM_Core_I18n_Schema::rebuildMultilingualSchema(["en_US","fr_CA"], NULL);'

I can see the problem (I saw this myself recently), but I don't have a 100% answer.

The problems stems from the problem in the first console error, "Unexpected Token". There's a JS file that gets created on the fly from a PHP template (l10n.js). Something in your WP instance (a plugin perhaps?) is modifying the output of l10n.js, causing a JavaScript error. In turn, that causes JS to stop running on the page and other errors occur.

If you click on the link in that line (it starts with admin.php?page=CiviC) then you'll see the modified file. Look for lines that appear to be added by a plugin. Hopefully you have a test site that you can compare with the same file to see the difference.

I can see the problem (I saw this myself recently), but I don't have a 100% answer. However, the solution is usually to rebuild your multilingual schema.

This problem is characterized by:

  • Multilingual mode is activated on your CiviCRM site.
  • Error in the browser console show files not found at a path with the word "undefined" in it.
  • Also, "DB Error: no such field" errors (though this can also be caused by missing extensions or failing to upgrade the database after upgrading the CiviCRM files).

Based on these instructions, here's how you rebuild the multilingual schema:

From within CiviCRM (CiviCRM 5.1+ only):

  • Go to Support menu » Developer » API Explorer.
  • Set Entity to System and Action to rebuildmultilingualschema.
  • Press the Execute button.

From the command line (Civi 5.0.1 and earlier):

Drupal 7

drush php-eval 'civicrm_initialize(); CRM_Core_I18n_Schema::rebuildMultilingualSchema(["en_US","fr_CA"], NULL);'

Drupal 8

drush php-eval '\Drupal::service('civicrm')->initialize(); CRM_Core_I18n_Schema::rebuildMultilingualSchema(["en_US","fr_CA"], NULL);'

WordPress

wp eval 'civicrm_initialize(); CRM_Core_I18n_Schema::rebuildMultilingualSchema(["en_US","fr_CA"], NULL);'

Source Link

I can see the problem (I saw this myself recently), but I don't have a 100% answer.

The problems stems from the problem in the first console error, "Unexpected Token". There's a JS file that gets created on the fly from a PHP template (l10n.js). Something in your WP instance (a plugin perhaps?) is modifying the output of l10n.js, causing a JavaScript error. In turn, that causes JS to stop running on the page and other errors occur.

If you click on the link in that line (it starts with admin.php?page=CiviC) then you'll see the modified file. Look for lines that appear to be added by a plugin. Hopefully you have a test site that you can compare with the same file to see the difference.