I created a module and put the following code in it. However, when I tried to activate the module it is giving this error message.

"This version is incompatible with the 6.14 version of Drupal core."

Here is the code:

<?php
// $Id$
/**
* @file
* Implements various blocks
*/
/**
* Implementation of hook_block().
*/
function approval_block($op = 'list' , $delta = 0, $edit = array()) {
switch ($op) {
case 'list':
$blocks[0]['info'] = t('Yahoo Rank');
$blocks[0]['cache'] = BLOCK_NO_CACHE;
return $blocks;
}
}

Please let me know what I am missing.

Thank you,

Comments

vm’s picture

how is your modules .info file constructed?

smedved’s picture

thank you for your response

The .info file is as follow

; Id$
name = Yahoorank
description = Blocks for displaying Yahoorank.
package = Website
core = 6.14

jevets’s picture

Try:

core = 6.x

smedved’s picture

thanks this make it work.

it work now but I can not see the block within the block enable page

jaypan’s picture

Probably best to start a new topic then, since that has nothing to do with being incompatible with 6.14.

Contact me to contract me for D7 -> D10/11 migrations.

johnhanley’s picture

You'll need to check the hook_block documentation as your code does not contain the required code to display the content of the block.