Created
January 7, 2012 12:01
-
-
Save deckerweb/1574576 to your computer and use it in GitHub Desktop.
Plugin: WP Single Post Navigation -- Customize parameters for "next post link" -- add this to functions.php of your theme or child theme
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter( 'wpspn_next_post_link', 'custom_wpspn_next_link' ); | |
/** | |
* WP Single Post Navigation: Add custom filters for "next post link" | |
*/ | |
function custom_wpspn_next_link() { | |
$args = array ( | |
'format' => '%link', // Change link format | |
'link' => '«', // Change link string | |
'in_same_cat' => FALSE, // Apply only to same category (default: FALSE) | |
'excluded_categories' => '' // Exclude categories (default: empty) | |
); | |
next_post_link( $args['format'], $args['link'], $args['in_same_cat'], $args['excluded_categories'] ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment