Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The D8 version was just added a few days ago. It took me a few minutes to figure it out so here are some basic directions since there isn't a readme.
The main difference is there is no cron run, rows are added to the index with hook_entity_update(), hook_entity_insert(), and hook_entity_delete(). This works for new nodes, but existing nodes need to be fired off manually.
- Install Module
- Edit settings under admin/config/system/prev-next
- Go to your content page and under bulk actions select 'Save Content" on all nodes that you want links for.
- Go to block settings and add the Prev/Next block
- Profit
Comments
Comment #2
naveenvalechaIt would be great to post the patch for the same.I'm tied off little bit and don't have much time for the patch.Please post the patch for the same.
Comment #3
devkinetic CreditAttribution: devkinetic commentedAre you talking about implementing the cron feature?
Comment #4
naveenvalechaDocument about the working features in 8.x branch i.e. in the Readme.txt file
Comment #5
josephleon CreditAttribution: josephleon at Last Call Media commentedHey guys, I added a patch for a README.txt issue I created here (https://www.drupal.org/node/2836456#comment-11829801) and later found this issue, I added the steps above. Please let me know if you would like for me to close the other ticket as a duplicate and I can throw the README.txt patch here.
Comment #6
mlncn CreditAttribution: mlncn at Agaric for Drutopia, Portside, Teachers with GUTS commentedThe fixes to the README did go in #2836456: Missing README.txt !
Similar text should be added to the module page:
Creating #3226512: Restore re-index and cron capability (D8) to deal with the missing re-index and cron functionality that makes these different instructions necessary!
Comment #7
nicxvan CreditAttribution: nicxvan commentedI would also say it would be helpful to mention you can call the service if you need the data programmatically:
\Drupal::service('prev_next.helper')->getPrevnextId($nid, 'next');
Comment #8
jcnventura CreditAttribution: jcnventura at 1xINTERNET commentedAdded #6 to the module page.