You are here

globallink.install in GlobalLink Connect for Drupal 8

Install, update and uninstall functions for the globallink module.

File

globallink.install
View source
<?php

/**
 * @file
 * Install, update and uninstall functions for the globallink module.
 */

/**
 * Implements hook_requirements().
 */
function globallink_requirements($phase) {
  $requirements = [];
  if (in_array($phase, [
    'runtime',
    'install',
  ])) {

    // Check for the soap client.
    if (!extension_loaded('soap')) {
      $requirements['globallink'] = [
        'title' => t('Soap client not installed'),
        'value' => t('Not installed'),
        'severity' => REQUIREMENT_ERROR,
        'description' => t('The Soap client for PHP is missing or outdated. Check the <a href="http://php.net/manual/en/book.soap.php">PHP soap documentation</a> for information on how to correct this.'),
      ];
    }
  }
  return $requirements;
}

Functions

Namesort descending Description
globallink_requirements Implements hook_requirements().