Hey,
I’m not sure how to describe it exactly.
I use buttons with dynamic content to display the “previous” and “next” post within a single post.
This is within the buttons:
Link:
{{{dc:post:permalink post=“prev”}}
Text:
{{{dc:post:title post=“prev”}}
and
Link:
{{{dc:post:permalink post=“next”}}
Text:
{{{dc:post:title post=“next”}}
I have inserted these two buttons into a content block.
And I show the content block with the following code in the function.php
function custom_post_arrows() {
if ( is_single() ) {
echo do_shortcode(’[cs_gb id=XXX]’);
}
}
add_action(‘x_before_the_content_end’, ‘custom_post_arrows’);
This works quite well.
Unfortunately, the client starts with 2 posts at the beginning.
Problem 1:
If you look at the last post entered, the Next button is not filled and only the button design appears, but not the dynamic content text.
This is also because there is no new post I guess?
Is there a workaround for a loop, so that you can click through all posts with next and previous?
Problem 2:
If you click on the first, i.e. oldest post, both buttons are not filled at all.
I hope you can help me out?
(red / green colours for demonstration only)
Thanks!


