home | career | drupal | java | mac | mysql | perl | php | scala | uml | unix

Drupal example source code file (advanced_help.install)

This example Drupal source code file (advanced_help.install) is included in the DevDaily.com "Drupal Source Code Warehouse" project. The intent of this project is to help you "Learn Drupal by Example".

PHP - Drupal tags/keywords

array, default, description, function, not, null, php, search, the, this, topic, true, type

The advanced_help.install Drupal example source code

<?php
// $Id: advanced_help.install,v 1.4.2.2 2010/03/01 21:12:39 fgm Exp $
/**
 * @file
 * Contains install and update functions for advanced_help.
 */

/**
 * Implements hook_install().
 */
function advanced_help_install() {
  // drupal_set_message('Installing advanced_help.');
}

/**
 * Implements hook_uninstall().
 */
function advanced_help_uninstall() {
  variable_del('advanced_help_last_cron');
}

/**
 * Implements hook_schema().
 */
function advanced_help_schema() {
  $schema['advanced_help_index'] = array(
    'description' => 'Stores search index correlations for advanced help topics.',
    'fields' => array(
      'sid' => array(
        'type' => 'serial',
        'unsigned' => TRUE,
        'not null' => TRUE,
        'description' => 'The primary key to give to the search engine for this topic.',
        'no export' => TRUE,
      ),
      'module' => array(
        'type' => 'varchar',
        'length' => '255',
        'default' => '',
        'not null' => TRUE,
        'description' => 'The module that owns this topic.',
      ),
      'topic' => array(
        'type' => 'varchar',
        'length' => '255',
        'default' => '',
        'not null' => TRUE,
        'description' => 'The topic id.',
      ),
      'language' => array(
        'type' => 'varchar',
        'length' => 12,
        'not null' => TRUE,
        'default' => '',
        'description' => 'The language this search index relates to.',
      ),
    ),
    'primary key' => array('sid'),
    'indexes' => array('language' => array('language')),
    'foreign keys' => array(
      'module' => array('system' => 'name'),
    ),
  );

  return $schema;
}

Other Drupal examples (source code examples)

Here is a short list of links related to this Drupal advanced_help.install source code file:

new blog posts

"Drupal" is a registered trademark of Dries Buytaert.

my drupal tutorials and examples  

Copyright 1998-2016 Alvin Alexander, alvinalexander.com
All Rights Reserved.

Beginning in 2016, a portion of the proceeds from pages under the '/drupal-code-examples/' URI will be donated to charity.