Showing a nodeasblock block as full content instead of teaser
By default, the Node As Block module displays a node in teaser mode. If you wish to show the full content, add the following to your template.php file. (note I’ve also added an edit link for good measure)
1 2 3 4 5 6 7 8 9 |
function mytheme_preprocess_nodeasblock(&$vars) { $node = $vars['node']; $vars['content'] = node_view(node_load($node->nid), FALSE, TRUE, TRUE); // Add an edit link if (node_access('update', $node)) { $vars['edit_link'] = l('['. t('edit') .']', 'node/'. $node->nid .'/edit', array('title' => t('Edit'))); } } |