get_adjacent_post wordpress
$prev_post = get_adjacent_post();
if( $prev_post )
echo '<a href="'. get_permalink($prev_post->ID) .'">'. $prev_post->post_title .'</a>';
get_adjacent_post wordpress
$prev_post = get_adjacent_post();
if( $prev_post )
echo '<a href="'. get_permalink($prev_post->ID) .'">'. $prev_post->post_title .'</a>';
get_adjacent_post wordpress
<?php
$prev = mod_get_adjacent_post('prev', array('post', 'custom1', 'custom2'));
$next = mod_get_adjacent_post('next', array('post', 'custom1', 'custom2'));
?>
<?php if($prev) : ?>
<a href="<?php echo get_permalink($prev->ID)?>">« Go back in time</a>
<?php endif; ?>
<?php if($next) : ?>
<a href="<?php echo get_permalink($next->ID)?>">Next: <?php echo $next->post_title; ?> »</a>
<?php endif; ?>
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us