Tag Lister

Looking for a way to easily embed an index list for a trip report or other collection of posts with a common tag? This is everything you need. Tag Lister creates a list of posts identified by a tag you specify in the shortcode, easy to embed in any WordPress post. There’s also an option to put in links to previous/next posts from the series rather than the sequential previous/next in your WordPress site.

Tag List

Use the [ trtag] to create the index list. Valid parameters are:

  • trtag – The tag to create the list from (REQUIRED)
  • trstyle – The display style for the list (Optional)
  • trheader – Text to display above the list (Optional)
  • trheadstyle – Formatting options for the list header (Optional)

The trtag and trheader parameters are straight text; just type in what you want to use. The other two are limited.

trstyle

Valid options for trstyle are h1-h6, p, ol and ul. The plugin will use your default CSS formatting for whichever you choose. Default is ul.

trheadstyle

Valid options for trheadstyle are h1-h6 and p. The plugin will use your default CSS formatting for whichever you choose. Default is h2.

Examples

The tag [ trtag=”WhatTheWat” trstyle=”ul”] renders the “WhatTheWat” tag as an unordered list with the default “More from this trip” in h2 as the header:

More from this trip:

To change the header text and the list style to h4 I adjust the tag to &#91taglist trtag=”WhatTheWat” trstyle=”h4″ trheader=”Trip Index”] which displays as shown below:

Trip Index

WhatTheWat: Travel Planning for a Bangkok Wedding

In Flight: EgyptAir Business Class New York to Asia

Checklist or Bucket List: The Pyramids at Giza

Cruising the Tonle Sap: Boating in Cambodia

Flying High over Angkor Wat

Sunrise at Angkor Wat, Along with Everyone Else

Previous/Next links

Use the shortcode &#91trprevnext] to create the previous/next links. Valid parameters are:

  • trtag – The tag to create the list from (REQUIRED)
  • trstyle – The display style for the links (optional)
  • trusetitle – Use the post title as the link text or just the words Previous/Next (optional)

The trtag parameter is straight text; just type in what you want to use.

trstyle

Valid options for trstyle are h1-h6 and p. The plugin will use your default CSS formatting for whichever you choose. Default is h4.

trusetitle

This is a boolean evaluation. If true then links will display using the original post titles. If false it will just display the words “<< Previous | Next >>” with the relevant hyperlinks. Default is true.

Note that if you insert this code on the first post of a series it will not display a “<< Previous” link because there is nothing before it. Ditto if you place it at the end for a “Next >>” link.

Examples

[ trprevnext=”WhatTheWat” trstyle=”ul” trusetitle=”1″ ] has an error in it; the “ul” option is not valid as a trstyle entry. The plugin defaults to h4 in such cases (also if that parameter is omitted). This example is on the first post of a series so only the >> link is shown.

[ trprevnext=”WhatTheWat” trstyle=”h3″ trusetitle=”false” ] makes the links larger (h3 rather than h4) and just the basic words, not the full post title.