You are here

browscap.install in Browscap 8.3

Install, update and uninstall functions for the Browscap module.

File

browscap.install
View source
<?php

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

/**
 * Implements hook_schema().
 */
function browscap_schema() {
  $schema['browscap'] = [
    'fields' => [
      'useragent' => [
        'type' => 'varchar',
        'length' => 191,
        'not null' => TRUE,
        'default' => '',
        'binary' => TRUE,
      ],
      'data' => [
        'type' => 'blob',
        'size' => 'big',
      ],
    ],
    'primary key' => [
      'useragent',
    ],
  ];
  return $schema;
}

/**
 * Implements hook_install().
 */
function browscap_install() {

  // Tell the user to run the import.
  drupal_set_message(t("You are required to run Browscap's import before utilizing the service."));
}

Functions

Namesort descending Description
browscap_install Implements hook_install().
browscap_schema Implements hook_schema().