Custom Lists

You can customise the default list styles that are registered by Delightful Downloads using the dedo_get_lists filter. This will allow you to add or remove list styles that are used by the [ddownload_list] shortcode and will also affect which list styles can be selected as the default list style in the Settings screen under the Shortcodes tab.

Don’t know CSS, HTML or PHP? Check out the Customizer Add-On.

Custom Lists Settings Screen

The following list styles are registered by default:

You will notice that various wildcards are used to enter dynamic content such as %url%, %title% and %date%. A full list of the available wildcards can be found here.

Add Lists

To add a new list style to those already registered by Delightful Downloads simply add a new key to the $lists array:

To completely replace the default output styles simply overwrite the $lists array:

You use a custom list like so, [ddownload_list style="icon_date"].

Remove Lists

Existing lists can be removed by simply unsetting them. The following snippet will remove the Title (File Size) list style:

All of the above code snippets should be added to your theme’s function.php file.