function node_link in Drupal 5
Same name and namespace in other branches
- 4 modules/node.module \node_link()
- 6 modules/node/node.module \node_link()
Implementation of hook_link().
File
- modules/
node/ node.module, line 1107 - The core that allows content to be submitted to the site. Modules and scripts may programmatically submit nodes using the usual form API pattern.
Code
function node_link($type, $node = NULL, $teaser = FALSE) {
$links = array();
if ($type == 'node') {
if ($teaser == 1 && $node->teaser && $node->readmore) {
$links['node_read_more'] = array(
'title' => t('Read more'),
'href' => "node/{$node->nid}",
'attributes' => array(
'title' => t('Read the rest of this posting.'),
),
);
}
}
return $links;
}