You are here

cas_ldap.install in CAS Attributes 6.3

Installation hooks for the CAS LDAP module.

File

cas_ldap.install
View source
<?php

/**
 * @file
 * Installation hooks for the CAS LDAP module.
 */

/**
 * Implements hook_requirements().
 */
function cas_ldap_requirements($phase) {
  $requirements = array();
  $t = get_t();

  // This should really be in the LDAP Integration module.
  if (!function_exists('ldap_connect')) {
    $requirements['cas_ldap'] = array(
      'title' => $t('LDAP PHP Extension'),
      'value' => $t('Missing'),
      'severity' => REQUIREMENT_ERROR,
      'description' => $t('CAS LDAP requires you to enable the <a href="@url">LDAP</a> PHP extension.', array(
        '@url' => 'http://us.php.net/manual/en/book.ldap.php',
      )),
    );
  }
  return $requirements;
}

Functions

Namesort descending Description
cas_ldap_requirements Implements hook_requirements().