Support » Plugin: Loop Post Navigation Links » Only URl

Viewing 1 replies (of 1 total)
  • Plugin Author Scott Reilly


    WordPress & Plugin Developer

    @stunomatic: Hi,

    That’s a good suggestion for a future set of template tags to add to the plugin.

    In the meantime, I recommending using the plugin to get the adjacent post object and then get its URL. Like so:

    // Get next post.
    // Could also use c2c_get_previous_or_loop_post() to get previous post.
    $post = c2c_get_next_or_loop_post();
    // Echo the post's permalink URL.
    echo get_permalink( $post );

    This could be condensed to one line if you like:

    echo get_permalink( c2c_get_next_or_loop_post() );

Viewing 1 replies (of 1 total)
  • The topic ‘Only URl’ is closed to new replies.