i4w_list_subscriptions

Usage:

This shortcode enables you to display a list of subscriptions to your subscribers, based on the currently logged in user.

By using different parameter combinations, this shortcode can be used to display different views of the subscriptions on file in your system, such as with the “status” filter set to “all”, “active” or “inactive”.

You can stipulate to display the list in ascending or descending order, based on the date the subscriptions was purchased.

You can also specify which fields you want included in the table display. The “official” list of accepted field names can be found here.

You can set your own headers for each column in the generated table.

Every item in the generated table is CSS-enabled. If you would rather apply a different style, you can do so by passing those CSS definitions that you wish to override.

This shortcode does NOT supports conditional branching with [ELSE_list_subscriptions].

Shortcode nesting is NOT supported.

Parameters:

status Is used to filter the list based on “valid” status. Can be ‘all, ‘active’ or ‘inactive’.
Required: No, defaults to ‘all’.
columns Is used to specify the columns for the generated table.
Required: No, defaults to ‘ProgramName,Status,BillingCycle,StartDate,PaidThruDate,NextBillDate,BillingAmt’.
headers Is used to specify columns headers for the generated table.
Required: No, defaults to ‘Program Name,Status,Cycle,Start,Paid Thru,Next Bill Date,Amount’ – if the columns are set to default, otherwise, the field names are used.
sort Is used to specify the order of display, ‘asc’ for ascending and ‘desc’ for descending, based on the date the subscription(s) were added to the database.
Required: No, defaults to ‘asc’.

Example:

CSS definition:

If you want to pass your own CSS style definitions to the shortcode, you must do so as follows:

The above CSS are the current defaults.

Please note that since the shortcode may be used multiple times on a single page/post to represent different views, the CSS elements’ ID’s will be automatically be randomized for each instance.

API:

There is no API function equivalent for this shortcode.