Aller directement à la fin des métadonnées
Aller au début des métadonnées

CiviCRM Configuration

CiviCRM provides, in my opinion, an invaluable configuration check-list.

The first two sections for Site Configuration and Viewing and Editing Contacts are specific to individual installations. Please complete these with your own settings.

Email Configuration

The first issue encountered for the Windows IIS installation is related to features not implemented in the PHP 5.2.13 package for Windows.
Please bear in mind that I am not a php developer. In fact, this is the first time I have modified php code with a successful outcome.
It is documented on that the feature mcrypt-create-iv is implemented in PHP 5.3.

  • CiviCRM Outbound Mail Settings require the php function "mcrypt-create-iv"
  • PHP 5.2.13 for Windows does not have this feature implemented. This feature became available in PHP 5.3 for Windows
  • CiviCRM is not yet compatible with PHP 5.3.

Will outbound mail work with this error? Doubtful.

Spending quite some time researching first what mcrypt-create-iv provided, second; how is it used in CiviCRM, and finally; is an alternative method available?

Setting the Outbound Mail configuration will lead to a message like the following being displayed on the page:


warning: mcrypt_create_iv() function.mcrypt-create-iv: Cannot open source device in C:\Inetpub\wwwroot\drupal\sites\all\modules\civiCRM\CRM\Utils\Crypt.php on line 69.
warning: mcrypt_generic_init() function.mcrypt-generic-init: Iv size incorrect; supplied length: 0, needed: 32 in C:\Inetpub\wwwroot\drupal\sites\all\modules\civiCRM\CRM\Utils\Crypt.php on line 73.

Eh? My research demonstrated that:

  1. mcrypt_create_iv() cannot be found
  2. a required variable with a length of 32 was required to execute mcrypt_generic_init(); it was not provided.

The first thing to be done was to research/find/code an alternative method to replicate the functionality of mcrypt_create_iv(). I discovered an alternative method after hours and research and decided to attempt the change:

  1. Copy c:\inetpub\wwwroot\drupal\sites\all\modules\civicrm\crm\utils\crypt.php to c:\inetpub\wwwroot\drupal\sites\all\modules\civicrm\crm\utils\crypt.php.bak; creating a backup of the original file
  2. Open the c:\inetpub\wwwroot\drupal\sites\all\modules\civicrm\crm\utils\crypt.php file in Notepad++ (or another editor)
  3. Replace the contents of the file with the following:
  4. Save the file
  5. Restart the webserver by accessing the windows command prompt and entering the following:
  6. Browse to http://localhost/drupal/index.php?q=civicrm/admin/setting/smtp&reset=1 and check that the error message has now gone...

    Although there is no error message after the changes, and the test email works, I cannot guarantee that this method is correct. However, after the current stage of data migration; when mailings are started, these changes can be confirmed.
    If an upgrade to Drupal/CiviCRM is planned, you will need to document the changes to the file and make the necessary changes to any new version.

  • Aucun