Giving Circles Plugin

Pure Charity Giving Circles

A plugin to display one or a list of your Giving Circles from the Pure Charity app.

It depends on the Pure Charity Base Plugin being installed and it’s credentials configured to work.

Installation

In order to install the plugin:

1. Download the plugin
2. Copy the `/purecharity-wp-givingcircles` folder to the `/wp-content/plugins` on your WP install
2. Activate the plugin through the ‘Plugins’ menu in WordPress
3. You’re done!

Template Tags

Giving Circles List

Function:

pc_giving_circles()

Returns:
A Giving Circle “Object”

Return Object Attributes:

  • name – string
  • members_count – string
  • profile – object
  • about – string
  • lives_impacted – int
  • cover – string(image_url)
  • avatar – string(image_url)
  • total_donations – string
  • slug – string

Example (show a list of giving circles with name and members_count in a page):

 <?php $gc_list = pc_giving_circles(); ?>
 <ul>
   <?php foreach($gc_list as $gc){ ?>
   <li> 
     <?php echo $gc->name ?>
     <small><?php echo $gc->members_count ?></small>
   </li>
   <?php } ?>
 </ul>

Single Giving Circle Information

Function:

pc_giving_circle($slug)

Parameters:

  • $slug – The slug of the giving circle you want to fetch.

Returns:
A Giving Circle “Object”

Return Object Attributes:

  • name – string
  • about – string
  • profile – object
  • about – string
  • lives_impacted – int
  • cover – string(image url)
  • avatar – string(image url)
  • founder – object
  • name – string
  • profile_url – string
  • avatar – string(image url)
  • organizers – array of objects
  • name – string
  • profile_url – string
  • avatar – string(image url)
  • membership_status – string
  • minimum_monthly_donation – string
  • backed_causes – array of objects
  • name – string
  • url – string
  • amount_donated – string
  • location – string
  • avatar – string(image_url)
  • total_donations – string
  • members – array of objects
  • name – string
  • profile_url – string
  • avatar – string(image url)
  • join_url – string

Example (show a giving circle’s name and members_count in a page):

 <?php $gc = pc_giving_circle('my-giving-circle'); ?>
 <h1> 
   <?php echo $gc->name ?>
   <small><?php echo count($gc->members) ?></small>
 </h1>

Shortcodes

Giving Circles Listing

No Giving Circles Found.

Possible parameters:

  • members_limit – (optional) Defaults to infinite. The number of members to show
  • backed_limit – (optional) Defaults to infinite. The number of backed causes to

Single Giving Circle Information


Available Types:

members_count – String
amount_donated – Money formatted String
member_avatars– Unordered list with the avatars of all the giving circle members