Upscale Your WordPress Post Pagination: Your Readers Will Thank You

Upscale Your WordPress Post Pagination: Your Readers Will Thank You

Splitting your longer posts into more easily digested bite-size pieces can be a incredibly effective technique for keeping readers engaged.

However, the out-of-the-box pagination support provided by WordPress is so basic so as to not be worth the effort.

If you really want to help your readers you need to forget about pagination and start thinking about content navigation.

If you want to provide real benefits to your readers navigate don't paginate
If you want to provide real benefits to your readers navigate don’t paginate

WordPress does support content pagination via the <!–nextpage–> tag. Adding this tag in your post body will cause a simple number-based navigation aid to be displayed at the bottom of each “page” of content.

Screengrab showing the built-in number-based pagination on a WordPress post
The built-in pagination is so lame, it’s hardly worth the effort

Whilst easy to implement (although make sure your < and > don’t get escaped otherwise nothing will happen) the result is of very limited benefit. Sure, your readers can see how many pages make up the post but it there is no indication whatsoever about what each page contains.

In many cases this would be crucial in providing an optimum user experience: perhaps readers want to go straight to your review’s verdict; maybe they are interested just in the match stats; perhaps they need the location map, or the contact details, or want to look at the gallery.

For long content, or even content that is highly structured, you don’t want pagination you want effective content navigation that helps your readers find what they want quickly and easily.

Advanced Content Pagination

Advanced Content Pagination is a WordPress plugin that upscales pagination considerably, making it a genuinely useful tool.

Screengrab showing ACP's button-style, titled navigation
This is what useful content navigation looks like!

As you can see from the example screenshot, the navigation aide looks pretty good without any modification and is generated simply by wrapping each section in your post body in a shortcode:

[nextpage title="title goes here"]
Content goes here...
[/nextpage]

The plugin does add a button to the Visual Editor although it’s just as easy to hand-code the shortcodes, in fact if you are adding the code to existing content then it’s probably easier to do it manually.

The plugin provides its own settings screen where the navigation buttons can be styled. There are also settings for whether to show the buttons at the top or bottom (or both) of the content and whether to reload the entire page when navigating or just load the new content via AJAX.

Screengrab of the ACP settings page
Plenty of settings to configure the navigation’s style and behavior

The plugin works with virtually all themes although certainly looks better in wider or full-width templates. it’s less effective in those themes that have narrower content areas (such as Twenty Twelve) where the number of visible navigation buttons can quickly outstrip the number of actual sections. The buttons will scroll (and pretty nicely too) but it’s not overly intuitive.

A Small Tweak

UPDATE (21 June) : The plugin has been updated to address the issue described below, so this tweak is no longer required. And yes, Piet makes a fair point about hacking plugin code. 

As good as ACP is, it does have one minor flaw and that is that any shortcodes that are contained within the [nextpage] shortcodes are left unprocessed.

To get around this, you need to make a small change to the plugin code. In the plugin’s main file (acp.php) lines 197 to 199 are:

{code}

return $html;
} else {
return $content;

{/code}

Replace that code with:

{code}

return do_shortcode( $html );
} else {
return do_shortcode( $content );

{/code}

Content Navigation A Valuable Tool

Whilst post pagination is practically worthless, content navigation brings genuine benefit to long and/or highly structured content by providing clear visual cues for readers and quick and easy access to the content’s components.

Advanced Content Pagination is a simple and easy pathway to generating content navigation and creating those visual cues. Your mileage will vary according to your theme but if your content has plenty of width then this plugin is definitely worth investigating further.

Do you publish long or structured content? Do you provide content navigation?