Following on from the tutorial on how to visually build adjacent post links with the repeater component. In this members-only tutorial we'll go through adding a custom condition that allows us add elements based on if the post is either the previous or next post.

An example use case for this is if we wanted to be able to add different icons for arrows, where they will need to be different in each post. We could also use this to add different labels.

In our code snippets, the php to add the custom condition is the following;

This is a premium members-only content.

To view the rest of the content, please sign up for membership ($37/month or $399 one-time).

Already a member? Log in below or here.

Need help implementing a tutorial in your site or want to hire me for custom work?

HIRE ME

Find the article helpful and wish to donate?

DONATE
magnifiercross
>
linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram
%d bloggers like this: