I’m trying to make wp list pages with thumbnails and other good stuff. But when i add the_permalink to my titles thumbnails etc and click on them, they are just refreshing the parent page and not getting the title(page) url. I’ll insert what I have maybe someone knows how to fix it? Will be happy for any help ! THANKS
What I have
<div id="archive-thumbnails-listing" >
<?php $pages = get_pages(array('child_of' => 352)); ?>
<?php foreach ($pages as $page): ?>
<div class="thumb22">
<div class="thumb20"><a href="<?php the_permalink(); ?>">
<?php echo get_the_post_thumbnail($page->ID, 'full'); ?></a></div>
<div class="thumb19"><a href="<?php the_permalink(); ?>"><?php echo $page->post_title; ?></a></div>
</div>
<?php endforeach; ?>
</div>
try this:
echo get_the_permalink($page->ID);