i have a parent PAGE and multiple sub-PAGES. I want to be able to pull the Title, Excerpt and a Custom field (vendor_img) from the sub-pages and have them appear in a list in the parent page.
I tried using this code...
<?php the_ID(); ?>
<?php $parent = $post->ID; ?>
while (have_posts()) : the_post();
<?php $image = get_post_meta($post->ID, 'vendor_img', true); ?>
<?php endwhile; ?>
but i receive an error message which you can see here on the parent page where i'm trying to get the child page info to appear in the list.
should I be placing a parent PAGE category name or id somewhere in that code? is the problem something else?
please advise. thanks in advance!