2

Custom annotation module

http://drupal.org

hi

Has anyone read the book: 'Pro Drupal Development'? Well, anyways, I'm trying to get a custom module to work, only I'm having difficulty.
The module is supposed to let users make an annotation (a type of note that only the user can see) to a web page.

My files:

<?php

/var/www/drupal-6.16/sites/all/modules/custom/annotate/annotate.module
// $Id$

/**
* @file
* Lets users add private annotations to nodes.
*
* Adds a text field when a node is displayed
* so that authenticated users may make notes.
*/

/**
* Implementation of hook_menu().
*/

function annotate_menu() {
$items['admin/settings/annotate'] = array(
'title' => 'Annotation settings',
'description' => 'Change how annotations behave.',
'page callback' => 'drupal_get_form',
'page arguments' => array('annotate_admin_settings'),
'access arguments' => array('adminsiter site configuration'),
'type' => MENU_NORMAL_ITEM,
'file' => 'annotate.admin.inc'
);

return $items;
}

/**
* Implementation of hook_nodeapi().
*/

function annotate_nodeapi(&$node, $op, $teaser, $page) {

global $user;
switch ($op) {
// The 'view' operation means the node is about to be displayed.
case 'view':

read more

Read »
Created by Dplanet 2 years 8 weeks ago
Category: Modules   Tags:

PSD to Drupal Theme

Drupal Development

Module Development

Get an Estimate

Best published scoops - Modules

Tags for Custom annotation module

Recent comments