Displays icons for navigation between your posts so practical and fast.
The Floating NextPrev displays buttons for navigation between your blog posts.
The icons are displayed only within the pages of posts and can promote a better navigation for your visitors.
You can contribute to the source code in our GitHub page.
Paste this code in functions.php
file of your theme:
add_filter( 'floating_nextprev_in_same_cat', '__return_true' );
Use this example in functions.php
file of your theme:
function floating_nextprev_exclude_categories( $excluded_categories ) { $excluded_categories = '1,2,3'; // add your categories ids. return excluded_categories; } add_filter( 'floating_nextprev_excluded_categories', 'floating_nextprev_exclude_categories' );
You can control the display using the floating_nextprev_display
filter.
Example how to display only in news category:
function floating_nextprev_only_in_news( $display ) { return in_category( 'news' ); } add_filter( 'floating_nextprev_display', 'floating_nextprev_only_in_news' );
Use the floating_nextprev_prev_title
and floating_nextprev_next_title
filters.
Example:
function floating_nextprev_prev_title( $title ) { return __( '←', 'textdomain' ); } add_filter( 'floating_nextprev_prev_title', 'floating_nextprev_prev_title' ); function floating_nextprev_next_title( $title ) { return __( '→', 'textdomain' ); } add_filter( 'floating_nextprev_next_title', 'floating_nextprev_next_title' );