You are here

pages_restriction.install in Pages Restriction Access 7

Same filename and directory in other branches
  1. 8 pages_restriction.install

Install hooks for the Pages Restriction module.

File

pages_restriction.install
View source
<?php

/**
 * @file
 * Install hooks for the Pages Restriction module.
 */

/**
 * Implements hook_schema().
 */
function pages_restriction_schema() {
  $schema['cache_pages_restriction'] = array(
    'description' => 'Table to store data related to the Pages Restriction to do less processing on every page load.',
    'fields' => array(
      'id_session' => array(
        'description' => 'Primary Key: Unique Cache identifier for my table.',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ),
      'next_page_path' => array(
        'description' => 'Next URL Path rule to validate.',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ),
      'restrict_rules' => array(
        'description' => 'Save rules in database',
        'type' => 'varchar',
        'length' => 255,
        'not null' => TRUE,
        'default' => '',
      ),
    ),
    'primary key' => array(
      'id_session',
    ),
  );
  return $schema;
}

Functions

Namesort descending Description
pages_restriction_schema Implements hook_schema().