Answers.Body: <p>If your site only needs english then as a temporary workaround you could try:</p>
  <ol>
  <li>On the command line go into the civicrm folder, where the composer.json file is.</li>
  <li>Type <code>composer require symfony/polyfill-intl-icu</code></li>
  <li>See if that works. It installs drop-in replacement functions for some of the intl functions.</li>
  </ol>
  <p>You can undo it with <code>composer remove symfony/polyfill-intl-icu</code></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-04-14T18:51:10.790Z
Answers.Text: Ah, I was so hopeful.  But it appears that this ancient version of Debian won't even do this.  Had to install composer first of all and then got "Your requirements could not be resolved to an installable set of packages" when trying to run the above. Then it tells me that I need to install PHP's intl extension which is what was being fixed in the first place.  Haaa!  
  I am building a new server even as I type this.
  Thanks for the suggestion!!
Answers.UserDisplayName: thomjones
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-04-14T18:17:48.137Z
Answers.LastActivityDate: 2022-04-14T18:17:48.137Z
Answers.UserDisplayName: Demerit
Body: <p>Running PHP 7.3 on WordPress 5.9.3 (latest).  But on a very old Debian install. So old that I cannot install php-intl. So I get the message that CiviCRM will fail over to a less accurate method of formatting currency.<br />
  This cropped up because I finally was updating CiviCRM to the latest version as well as getting all extensions up to date.
  Now, however, trying to check any reports or individual contributions the browser generates a 'Cannot connect to the server' message and the apache error.log shows similar to:</p>
  <pre><code>PHP Fatal error:  Uncaught Error: Class 'NumberFormatter' not found in /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/Civi/Core/Format.php:173\nStack trace:\n#0 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/Civi/Core/Format.php(49): Civi\\Core\\Format-&gt;getMoneyFormatter('USD', 'en_US')\n#1 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Smarty/plugins/modifier.crmMoney.php(31): Civi\\Core\\Format-&gt;money('45.00', 'USD')\n#2 /usr/share/wordpress/wp-content/plugins/files/civicrm/templates_c/en_US/%%3D/3D4/3D44E36C%%Selector.tpl.php(15): smarty_modifier_crmMoney('45.00', 'USD')\n#3 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/packages/Smarty/Smarty.class.php(1914): include('/usr/share/word...')\n#4 /usr/share/wordpress/wp-content/plugins/files/civicrm/templates_c/en_US/%%5E/5EA/5EA30681%%Tab.tpl.php(82): Smarty-&gt;_smarty_include(Array)\n#5 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/packages/Smarty/Smarty.class.php(1914): include('/usr/share/word...')\n#6 /usr/share/wordpress/wp-conten in /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/Civi/Core/Format.php on line 173, referer: http://192.168.1.10/wp-admin/admin.php?page=CiviCRM&amp;q=civicrm%2Fcontact%2Fview&amp;reset=1&amp;cid=23549
  </code></pre>
  <p>The plan is to move to a new server soon, but I wasn't quite ready to jump there yet.  It seems likely that the missing php-intl extension is the culprit for this, but I'm not totally sure nor am I sure of what to do about it (the code repository for php7.3 has since been taken down).
  Any thoughts?
  Thanks!</p>
  
Tags: <wordpress><php7>
Title: Class 'NumberFormatter' not found causing a fatal PHP error
ThreadText: # Class 'NumberFormatter' not found causing a fatal PHP error
  
  (Asked by: username_0 on 2022-04-14)
  
  Running PHP 7.3 on WordPress 5.9.3 (latest). But on a very old Debian install. So old that I cannot install php-intl. So I get the message that CiviCRM will fail over to a less accurate method of formatting currency.  
  This cropped up because I finally was updating CiviCRM to the latest version as well as getting all extensions up to date.
  Now, however, trying to check any reports or individual contributions the browser generates a 'Cannot connect to the server' message and the apache error.log shows similar to:
  
  ```
  PHP Fatal error:  Uncaught Error: Class 'NumberFormatter' not found in /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/Civi/Core/Format.php:173\nStack trace:\n#0 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/Civi/Core/Format.php(49): Civi\\Core\\Format->getMoneyFormatter('USD', 'en_US')\n#1 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/CRM/Core/Smarty/plugins/modifier.crmMoney.php(31): Civi\\Core\\Format->money('45.00', 'USD')\n#2 /usr/share/wordpress/wp-content/plugins/files/civicrm/templates_c/en_US/%%3D/3D4/3D44E36C%%Selector.tpl.php(15): smarty_modifier_crmMoney('45.00', 'USD')\n#3 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/packages/Smarty/Smarty.class.php(1914): include('/usr/share/word...')\n#4 /usr/share/wordpress/wp-content/plugins/files/civicrm/templates_c/en_US/%%5E/5EA/5EA30681%%Tab.tpl.php(82): Smarty->_smarty_include(Array)\n#5 /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/packages/Smarty/Smarty.class.php(1914): include('/usr/share/word...')\n#6 /usr/share/wordpress/wp-conten in /usr/share/wordpress/wp-content/plugins/civicrm/civicrm/Civi/Core/Format.php on line 173, referer: http://192.168.1.10/wp-admin/admin.php?page=CiviCRM&q=civicrm%2Fcontact%2Fview&reset=1&cid=23549
  
  ```
  
  The plan is to move to a new server soon, but I wasn't quite ready to jump there yet. It seems likely that the missing php-intl extension is the culprit for this, but I'm not totally sure nor am I sure of what to do about it (the code repository for php7.3 has since been taken down).
  Any thoughts?
  Thanks!
  
  **Tags:** wordpress, php7
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2022-04-14. Score: 1
  
  If your site only needs english then as a temporary workaround you could try:
  
  1. On the command line go into the civicrm folder, where the composer.json file is.
  2. Type `composer require symfony/polyfill-intl-icu`
  3. See if that works. It installs drop-in replacement functions for some of the intl functions.
  
  You can undo it with `composer remove symfony/polyfill-intl-icu`
  
  > **Comments:**
  > **username_0**: Ah, I was so hopeful.  But it appears that this ancient version of Debian won't even do this.  Had to install composer first of all and then got "Your requirements could not be resolved to an installable set of packages" when trying to run the above. Then it tells me that I need to install PHP's intl extension which is what was being fixed in the first place.  Haaa!   I am building a new server even as I type this. Thanks for the suggestion!!  
  
  ---
  
  