The [charitable_donors] shortcode allows you to display a list of donors to one or all of your campaigns on a page. It uses the same frontend template as the Donors widget, so its output is similar — it just provides you with flexibility to show the Donors in different spots.
Parameters
numberNumber of donors to show. Default is10.orderbyMay bedate,donationsoramount. Default isdate.orderMay beASC(ascending order) orDESC(descending order). Default isDESC.campaignMay be set to the ID of a campaign,currentto display the donors to the campaign currently being viewed, orallor0to display donors to any campaign. Default is0(donors to any campaigns).distinct_donorsOnly show unique donors. May be set to0(don’t show distinct) or1(show distinct). If a donor has donated more than once, they will only appear in the list once, with their donation amount calculated based on all their donations. Default is0.orientationMay beverticalorhorizontal. Default ishorizontal.show_nameWhether the name should be shown. May be1(show) or0(don’t show). Default is1.show_locationWhether the donor’s location should be shown. May be1(show) or0(don’t show). Default is0.show_amountWhether the donor’s donated amount should be shown. May be1(show) or0(don’t show). Default is1.show_avatarWhether the donor’s avatar should be shown. May be1(show) or0(don’t show). Default is1.hide_if_no_donorsWhether the shortcode should display anything if no one has donated yet. May be1(hide) or0(don’t hide). Default is0.
Plus, if Gift Aid is activated and on version 1.1 or above, the following setting is available:
show_gift_aidWhether to display the Gift Aid amount for the donation. May be1(show) or0(don’t show). Default is0.
Usage
Default usage:
[charitable_donors]
Show donors to the current campaign (to be used on a campaign page):
[charitable_donors campaign=current]
Show donors to a specific campaign (replace 123 with the ID of the campaign):
[charitable_donors campaign=123]
Show a donor leaderboard, ordered by amount donated:
[charitable_donors orderby=amount]
Show donors in a vertical list:
[charitable_donors orientation=vertical]
Only show donor’s names (hide amount, location and avatar):
[charitable_donors show_name=1 show_location=0 show_amount=0 show_avatar=0]
Show the Gift Aid amount for a donor’s donation (requires Charitable Gift Aid 1.1+):
[charitable_donors show_gift_aid=1]
