<?php $related = ugly_get( 'related' ); ?>
<?php if ( $related ) : ?>
<aside class="related">
<h2>Keep reading</h2>
<ul>
<?php foreach ( $related as $post ) : ?>
<li><a href="<?php echo esc_url( get_permalink( $post ) ); ?>"><?php echo esc_html( get_the_title( $post ) ); ?></a></li>
<?php endforeach; ?>
</ul>
</aside>
<?php endif; ?>Lists and data
Related posts picked by handPro
Pick related posts by hand and print them under the article.
1 minute Needs UglyFields Pro
Did this article answer your question?
Thank you. It helps us make the documentation better. Need more help?