Adding a New Page in WordPress

This article is excerpted from WordPress 24-Hour Trainer by George Plumley. (ISBN: 978-0-470-55458-6, Copyright 2010 Wiley Publishing Inc.)

In this lesson, it’s time to cover the functions unique to WordPress pages, such as using page templates or creating sub-pages.


Pages vs. Posts

In older versions of WordPress there was often only one word on the entire screen to visually tell you whether you were about to add a post or a page. In the most recent versions there are enough differences to easily avoid that confusion, as you can see from the tops of both screens shown in Figure 10-1.

Figure 10-1

The more common problem these days is a conceptual one: how exactly do posts and pages differ? A detailed discussion of this was covered in Lesson 1, but it’s worth running over a couple of points again here.

If you’re simply running a blog, the distinction is fairly clear: most of the content of your site is in the form of posts, with the newest ones displaying on the homepage, whereas pages are used occasionally for content that rarely changes. However, if you’re using WordPress to run a website (assuming for a moment that it has no blog section), pages take on a more important role and posts are more isolated bits of information rather than all belonging to “a blog.”

Organizational structure—categories and tags vs. pages and sub-pages—is the primary difference between posts and pages, but a couple of other differences exist when working in the Add/Edit screens. Let’s have a look at those next.

The Add Page Options

The first thing you notice is that there are fewer options on an Add New Page screen, as this overview in Figure 10-2 demonstrates.

Figure 10-2

Gone from this screen are Tags and Categories, Excerpts, and Trackbacks. There are several new options over on the right-hand side in the Attributes box.

I’ll leave the first of these—Parent—for the next section. The option below it is the Template menu. This displays all the page templates available for the theme you’re currently using. For the default theme, the drop-down looks like Figure 10-3.

Figure 10-3

Page templates have layouts that can differ from the default page layout as much as the theme developer likes, though typically what these templates do is display specific information. In the case of the default theme, for example, the Links template shows all of the link categories as a series of lists. You wouldn’t even need to enter any text for that page, other than the title.

Below the Template menu is the Order input box. In the automatic page menu that WordPress generates, pages are ordered alphabetically according to their titles. You can override that by entering numbers in the Order boxes for each page. It can be a bit cumbersome if you have a lot of pages and need to change the order at some point, but it works. Plugins are available for WordPress that offer simpler ways of handling this, the most popular of which is My Page Order.

Creating Sub-Pages

The other option in the Attributes box of the Add New Page screen is the Parent menu. This drop down—shown in Figure 10-4—allows you to choose a parent for the page you’re creating; that is, you can make it a sub-page of some existing page.

Figure 10-4

As you can see from this, some of the pages are shown with an indent. That means they’re sub-pages of the first flush-left page above it. In a very complex web setup you could have sub-pages of sub-pages, as deeply nested as you need.

You can change the relationship of a page to other pages at any time by using this same drop-down menu while editing the page.

This article is excerpted from WordPress 24-Hour Trainer by George Plumley. (ISBN: 978-0-470-55458-6, Copyright 2010 Wiley Publishing Inc.)



Leave a Reply

Your email address will not be published. Required fields are marked *