1. Home
  2. Documentation
  3. Posts Table Pro
  4. Posts Table Pro Options
  5. Links in the posts table

Links in the posts table

Your posts table will automatically link certain columns to the relevant single post page, category archive page, or author archives. Use the links option to disable them, or to have more fine-grained control over which columns are formatted as links.

Please note: links within the main content, excerpt or custom field columns are not controlled by the links option. Please see our article on adding custom links for more information.

By default, your table will create the following links:

  • The ID, title, and image columns will link to the single post page.
  • The categories, tags and any taxonomy column will link to the relevant term archive page.
  • The author column will link to the author archive page.
WordPress table default column links

Table with all clickable columns added to the table and formatted as links.

The links option can be controlled globally on the plugin settings page, or directly in the shortcode for each individual table. It can include the following values:

  • Use all to make all possible columns in the table clickable (this is the default).
  • Use none or false to disable all links to the single post page.
  • You can also use any combination of the following keywords, as a comma-separated list:
    • id – The ID column will be clickable (links to post)
    • image – The image column (links to post)
    • title – The title column (links to post)
    • author – The author column (links to author archive page)
    • categories – The categories column (links to category archive page)
    • tags – The tags column (links to tag archive page)
    • terms – Any custom taxonomy column (links to taxonomy archive page)

For example, if you use image,title for the Links option then only the ‘image’ and ‘title’ columns will link to the single post page.

On the plugin settings page

You will find the ‘Links’ option on the plugin settings page (Settings -> Posts Table Pro). Enter a comma separated list of the columns that you would like to link to the single post page. For example:

Using the shortcode

You can also add the links option directly to the posts table shortcode. This allows you to control the links for individual tables, instead of globally.

Examples:

  • [posts_table links="all"] – All possible columns will link to the single post page.
  • [posts_table links="none"] – All links to the single post page are disabled.
  • [posts_table links="title,terms"] – Only the title and custom taxonomy columns are clickable.

If you want to have links from your custom taxonomy column, but not other columns (such as title), use terms in your links option. E.g:

[posts_table links="terms"]

Note: you cannot use the taxonomy column name in the links option – instead, just add terms to make all taxonomy columns clickable.

You cannot control custom field links using the links option. Please see our article on custom links for more information.

Search on click

By default, clicking on a category, tag, author or custom taxonomy term in the table will search (i.e. filter) the table by that value. This is a quick way of filtering the table if you have lots of posts.

You can disable this search_on_click feature so that when someone clicks on a category, tag, author or custom taxonomy term, then they will be taken to the relevant category/tag/author/taxonomy archive instead. Example:

[posts_table columns="title,categories,tags" search_on_click="false"]

Tip: This option will only work correctly if your theme includes archive pages for categories/tags/custom taxonomy terms.

Yes! You can do this by using Posts Table Pro with the free Page Links To WordPress plugin. This plugin lets you add a URL to any page, post or custom post (e.g. to a PDF in your Media Library or a page on an external website). When someone clicks on a link to view the page/post/custom post, they will be taken to this URL instead.

For example, a lot of Posts Table Pro users find this helpful when creating a WordPress document library with downloadable document links in the table.

The above instructions tell you how to control the links to the single post page. You can also use Posts Table Pro to create other types of link, for example links to a third party URL or a downloadable document. You can add these link as clickable text, or you can even add clickable buttons, images or icons.

Please see our separate article on how to do this.

Was this article helpful?

Related Articles