Projet

Général

Profil

Révision b433176d

Ajouté par Assos Assos il y a environ 4 ans

Weekly update of contrib modules

Voir les différences:

drupal7/sites/all/modules/colorbox/colorbox.install
5 5
 * Install, update and uninstall functions for the colorbox module.
6 6
 */
7 7

  
8
/**
9
 * Implements hook_enable().
10
 */
11
function colorbox_enable() {
12
  drupal_set_message(t('Thanks for installing Colorbox'));
13
  drupal_set_message(t('You may configure Colorbox by visiting <a href="@url_settings">@url_settings</a>', array(
14
    '@url_settings' => url('admin/config/media/colorbox'),
15
  )));
16
}
17

  
8 18
/**
9 19
 * Implements hook_requirements().
10 20
 */
......
22 32
        'title' => $t('Colorbox plugin'),
23 33
        'value' => $t('@e: At least @a', array('@e' => $error_type, '@a' => COLORBOX_MIN_PLUGIN_VERSION)),
24 34
        'severity' => REQUIREMENT_ERROR,
25
        'description' => $t('!error You need to download the !colorbox, extract the archive and place the colorbox directory in the %path directory on your server.', array('!error' => $error_message, '!colorbox' => l($t('Colorbox plugin'), $library['download url']), '%path' => 'sites/all/libraries')),
35
        'description' => $t('!error You need to download the !colorbox, extract the archive and place the colorbox directory in the %path directory on your server.', array(
36
          '!error' => $error_message,
37
          '!colorbox' => l($t('Colorbox plugin'),
38
          $library['download url']),
39
          '%path' => 'sites/all/libraries',
40
        )),
26 41
      );
27 42
    }
28 43
    elseif (version_compare($library['version'], COLORBOX_MIN_PLUGIN_VERSION, '>=')) {
......
37 52
        'title' => $t('Colorbox plugin'),
38 53
        'value' => $t('At least @a', array('@a' => COLORBOX_MIN_PLUGIN_VERSION)),
39 54
        'severity' => REQUIREMENT_ERROR,
40
        'description' => $t('You need to download a later version of the !colorbox and replace the old version located in the %path directory on your server.', array('!colorbox' => l($t('Colorbox plugin'), $library['download url']), '%path' => $library['library path'])),
55
        'description' => $t('You need to download a later version of the !colorbox and replace the old version located in the %path directory on your server.', array(
56
          '!colorbox' => l($t('Colorbox plugin'),
57
          $library['download url']),
58
          '%path' => $library['library path'],
59
        )),
41 60
      );
42 61
    }
43 62
  }
......
63 82
}
64 83

  
65 84
/**
66
 * Delete the unused colorbox_title_trim and
67
 * colorbox_title_trim_length variables.
85
 * Implements hook_update_N().
86
 *
87
 * Delete the unused colorbox_title_trim and colorbox_title_trim_length
88
 * variables.
68 89
 */
69 90
function colorbox_update_7002() {
70 91
  $ret = array();
......
117 138

  
118 139
  return $ret;
119 140
}
120

  

Formats disponibles : Unified diff