prev_next_content

Categories

Component ID

2281811

Component name

prev_next_content

Component type

module

Maintenance status

Development status

Component security advisory coverage

not-covered

Component created

Component changed

Component body

Provide a variable: $prev_next_content for 'node.tpl' to display links of the previous and next node which are the same type with current node.

Similar project: Previous/Next API

Contrast with module: prev_next, this module is more simple, and most sites can use directly, e.g. http://www.w3cplus.com is using this module's function now.

prev_next_demo.jpg

Sandbox project page: https://drupal.org/sandbox/stevenjia/2281811

git clone stevenjia@git.drupal.org:sandbox/stevenjia/2281811.git prev_next_content

Usage:

1.Enable content types which should display "Prev | Next" links at:"admin/config/user-interface/prev_next_content_settings".

2.Find a position to output the $prev_next_content variable in node.tpl.php:

<!-- Prev next content -->
<?php if (isset($prev_next_content)): ?>
  <?php print $prev_next_content; ?>
<?php endif; ?>