Alex
Alex

Reputation: 929

Show Wordpress Child Pages as a menu

I'm creating a map site on the footer.php and I'm showing it using the wp_nav_menu(); function, but I have another section inside the footer in which I want to show only the child from a parent page.

I was trying to use wp_list_pages(); function but I didn't get the result I wanted.

How should I make this work?

Code of my footer.php:

      <div class="footer__catalog">
          <h5 class="footer__title">Catálogo</h5>
          <div class="footer__list">
              <?php
                    $args = array (
                        'title_li' => __('Catalogo')
                    );
               ?>
              <?php wp_list_pages( $args ); ?>
          </div>
      </div>

And this is the result I want:

This is what I've got.

Upvotes: 0

Views: 48

Answers (1)

Michael Jaros
Michael Jaros

Reputation: 4681

Have you tried also passing the child_of parameter? See the Wordpress function reference.

Upvotes: 1

Related Questions