Exclude several pages from wp_page_list

admin

Administrator
Staff member
Hye guys. I have wordpress template.php with listing custom pages. I need to exclude from my listing 2 pages. Is it possible? I'll give what I have maybe somebody knows an answer. Will be happy to solve this problem . THANKS!

<strong>WHAT I HAVE</strong>

Code:
   &lt;?php /* Template Name: # photography all archive */  get_header('photography'); ?&gt;

&lt;div class="base-content"&gt;

   &lt;div id="archive-thumbnails-listing" &gt;
    &lt;?php $pages = get_pages(array('child_of' =&gt; 379,403)); ?&gt;

     &lt;?php foreach ($pages as $page): ?&gt;
        &lt;div class="thumb12"&gt;
        &lt;div class="thumb20"&gt;&lt;a href="&lt;?php the_permalink(); ?&gt;"&gt;
            &lt;?php echo get_the_post_thumbnail($page-&gt;ID, 'full'); ?&gt;&lt;/a&gt;&lt;/div&gt;
    &lt;div class="thumb19"&gt;&lt;a href="&lt;?php echo get_the_permalink($page-&gt;ID); ?&gt;"&gt;&lt;?php echo $page-&gt;post_title; ?&gt;&lt;/a&gt;&lt;/div&gt;
        &lt;/div&gt;

    &lt;?php endforeach; ?&gt;

     &lt;/div&gt;

&lt;/div&gt;


&lt;?php
$args = array(
   'exclude' =&gt; array(403), // exclude posts 379 and 403,

);

$pages = get_pages( $args ); ?&gt;

&lt;?php get_footer(); ?&gt;