WordPress pages often contain static content that should be reachable at any time. Common uses for WordPress pages are website and author descriptions, contact forms, affiliate information, and more. Making sure that these pages can be found and navigated to quickly is paramount.
First, decide where you want to generate a linked list of all your pages. If you're comfortable using pages for navigation, then you probably want to put the pages listing directly below your main site identification elements, in header.php
. Open your chosen template file and insert the following:
<ul> <?php wp_list_pages(); ?> </ul>
Next, open your theme in your browser and take a look at the spot where you inserted the appropriate code. Depending on your site's styles and the pages that you've created, the output for this function call should look like the main content area in the following screenshot: