Sheets2Table Help – Customizing Shortcodes

Sheets2Table uses shortcodes to customize the table.

Customizing shortcodes

  1. Click on the Shortcodes tab in the Sheets2Table plugin
    Shortcode tab
  2. Locate the file associated with the Google Sheet data that you want to display. Click the Customize link.
    Customize shortcode
  3. Select the columns to display. Press the Generate shortcode button.
  4. Copy the updated shortcode and add to a page or post
    Updated shortcode

Manual shortcode edit

The shortcode customization tool provides a basic level of functionality. There is more that shortcodes offer.

Here is an empty shortcode:

[sheets2table-render-table csv_file="" columns="" titles="" options=""]
Shortcode Fields
  • sheets2table-render-table: This is the name of shortcode that is registered to the sheets2table plugin
  • csv_file: The name of the CSV file to display
  • columns: The exact name of the column in the CSV file/Google Sheet. Each column is separated by a comma.
  • titles: The text displayed in the table generated by the shortcode
  • options: Options such as responsive table and always get latest data
Modifying the shortcode

columns: Only the columns listed in the shortcode will be displayed. The columns will be displayed in the order they appear in the shortcode.

titles: The number of elements in the titles should match that in the columns. The text in the title field is what is displayed in the table header.

Standard shortcode

For the demo file of city temperature
(Google sheet ID 1VpIdIyHwFsjydEvLJsUjc9zCwrTJwbRS1mow1Y5yqX8).

[sheets2table-render-table csv_file="average-daily-temp.csv" columns="Location, High (Jan), High (Apr), High (Jul), High (Oct)" titles="Location, High (Jan), High (Apr), High (Jul), High (Oct)" options=""]

Shortcode default

Modified shortcode:
[sheets2table-render-table csv_file="average-daily-temp.csv" columns="Location, High (Oct), High (Jul), High (Apr), High (Jan)" titles="Location, October, July, April, January" options=""]

Notice that that columns are in reverse order and the titles are chaged.

Customized shortcode

<– Previous

  Next –>