about_this_node_block_contents()
about_this_node/about_this_node.module, line 79
Prepares the block and routes it to the appropriate theme function
<?php
function about_this_node_block_contents() {
$output = '';
$id = arg(1);
$node_info = array();
if (is_numeric($id)) {
$pagetype = arg(0);
switch ($pagetype) {
// This version of about_this_node only displays a block for node page types (i.e., not user pages, etc.)
case 'node':
$node = node_load($id);
$allowed_nodetypes = variable_get('about_this_node_nodetypes', array('story'));
// Conditional will return 0 (FALSE) if it isn't an allowed node type
if ($allowed_nodetypes[$node->type]) {
$output .= theme('about_this_node_node', about_this_node_get_info($node), $node);
}
break;
}
}
return $output;
}
?>