Donation Leaderboard (Donor Wall)

{wcdp_leaderboard}

(replace {} with [])

The Donation Leaderboard shortcode allows you to easily display a dynamic and customizable donation leaderboard on your website or platform. This shortcode is especially useful for showcasing top donors, encouraging healthy competition among contributors, and recognizing those who have generously supported your cause or project.

  • Lisa donated $50.00
    5 days ago
  • Michael donated $70.00
    5 days ago
  • Matthew donated $20.00
    6 days ago
  • Jane donated $60.00
    6 days ago
  • Richard donated $15.00
    2 weeks ago
  • Eva donated $80.00
    2 weeks ago
  • Emily donated $15.00
    3 weeks ago
  • Tim donated $10.00
    1 month ago
  • Ahmed donated $65.00
    1 month ago
  • Susan donated $70.00
    1 month ago
  • Christopher donated $60.00
    2 months ago
  • Emily donated $50.00
    2 months ago
  • Joseph donated $35.00
    2 months ago
  • Maria donated $65.00
    2 months ago
  • Robert donated $95.00
    2 months ago
  • Matthew donated $70.00
    2 months ago
  • Christopher donated $40.00
    3 months ago
  • Robert donated $90.00
    3 months ago
  • Joseph donated $75.00
    3 months ago
  • Linda donated $45.00
    3 months ago

{wcdp_leaderboard}
(replace {} with [])

By default, this shortcode will generate a leaderboard displaying the last 10 donations based on the standard settings. However, you can fully customize the display using various attributes.

  1. limit (optional):
    • Specifies the number of top donors to display on the leaderboard.
    • Default: 10
    • Example: {wcdp_leaderboard limit="5"} will display 5 donations.
  2. id (optional):
    • Specifies the ID of the products associated with donations to consider.
    • Default: “-1” (any product)
    • Example: {wcdp_leaderboard id="1"} will display the leaderboard for specific products.
  3. orderby (optional):
    • Determines the sorting order of the leaderboard.
    • Values: “date” or “total”
    • Default: “date”
    • Example: {wcdp_leaderboard orderby="total"} will display the leaderboard based on order total (so not just the amount of the donation item)
  4. style (optional):
    • Sets the style of the leaderboard.
    • Values: 1 or 2
    • Default: 1
    • Example: {wcdp_leaderboard style="2"} will display the leaderboard in an alternative style.
  5. split (optional):
    • Divides the leaderboard, revealing the next x donations in the list.
    • Default: -1 (disabled)
    • Example: {wcdp_leaderboard split="5"} will split the leaderboard to show the next 5 donations on demand.
  6. button (optional):
    • Defines the text of the “Show more” button for split leaderboards. Only has an effect when split is set.
    • Default: “Show more”
    • Example: {wcdp_leaderboard split="10" button="Load additional donations"}

Please do not forget to use [] instead of {}

Setting Global Leaderboard options

Please do not forget to set the global leaderboard settings via the plugin settings page. You can disable the heading/description by leaving it blank.

Placeholders

You can use the following placeholders (using {}) in the input fields to dynamically display specific information:

  • {firstname}: Display the first name of the order.
  • {firstname_initial}: Display the initial of the first name.
  • {lastname}: Display the last name of the order.
  • {lastname_initial}: Display the initial of the last name.
  • {company}: Display the company associated with the order.
  • {company_or_name}: Display the company name or individual’s name.
  • {amount}: Display the order total amount.
  • {timediff}: Display the human-readable time difference from the order date (e.g. 1 week ago)
  • {datetime}: Display the order date and time.
  • {date}: Display the order date.
  • {city}: Display the donor’s city.
  • {country}: Display the donor’s country.
  • {country_code}: Display the country code associated with the order.
  • {postcode}: Display the postal code associated with the order.
  • {currency}: Display the currency code associated with the order.
  • {comment}: Display the order note.
  • {anonymous}: Display a message indicating an anonymous donor (just returns “Anonymous donor” in a stylable tag).

Anonymous / public donation

You can show different text based on if users checked the anonymous / public checkbox on checkout. You have to enable this checkbox first.

Let’s say you only want to show the name of the user only when the checkbox is checked (opt-in):

  • Activate the checkbox
  • Set text of checkbox to “Show my name publicly in the leaderboard”.
  • Set “Leaderboard item heading (Checkout checkbox checked)” to e.g. “{firstname} {lastname} donated {amount}”
  • Set “Leaderboard item heading (Checkout checkbox unchecked)” to e.g. “Someone from {city} donated {amount}”
  • Set “Leaderboard item description” to e.g. “{timediff}” (will apply in both cases)

If you want to show the name of the donor when the checkbox is unchecked (opt-out) please use a setup similar to this:

  • Activate the checkbox
  • Set text of checkbox to “Do not show my name in the leaderboard”.
  • Set “Leaderboard item heading (Checkout checkbox checked)” to e.g. “Anonymous donation from {city}”
  • Set “Leaderboard item heading (Checkout checkbox unchecked)” to e.g. “{firstname} {lastname} donated {amount}”
  • Set “Leaderboard item description” to e.g. “{timediff}” (will apply in both cases)