You are here

function node_link in Drupal 4

Same name and namespace in other branches
  1. 5 modules/node/node.module \node_link()
  2. 6 modules/node/node.module \node_link()

Implementation of hook_link().

File

modules/node.module, line 824
The core that allows content to be submitted to the site.

Code

function node_link($type, $node = 0, $main = 0) {
  $links = array();
  if ($type == 'node') {
    if ($main == 1 && $node->teaser && $node->readmore) {
      $links[] = l(t('read more'), "node/{$node->nid}", array(
        'title' => t('Read the rest of this posting.'),
        'class' => 'read-more',
      ));
    }
  }
  return $links;
}