DOCS

Team & peer-to-peer campaigns

Fundations supports peer-to-peer fundraising where individual fundraisers create their own pages under a shared campaign, optionally organised into teams. This is a free feature.

Why use it

Peer-to-peer fundraising multiplies reach. Instead of one campaign page collecting all donations, each participant has their own page they can share with their personal network. Teams add a second layer: groups of participants compete or collaborate toward a shared team goal under the main campaign.

What it does

Fundations uses three content types:

Content typeDescription
CampaignA get_fund_action post with _get_fund_is_campaign = true. Serves as the parent container.
TeamA get_fund_team post linked to a campaign via _get_fund_campaign_id. Groupings of individual fundraisers.
Individual fundraising pageA get_fund_action post linked to a campaign and/or team via _get_fund_campaign_id and _get_fund_team_id.

Every fundraising page has a structure_type that describes its relationship:

Structure typeDescription
individualStandalone page, not linked to a team
join_teamLinked to an existing team under a campaign
create_teamCreates a new team and links the page to it

How hierarchy works

Fundations does not use WordPress post parent relationships. All hierarchy is stored in meta:

  • A campaign has no parent; it is identified by _get_fund_is_campaign = true.
  • A team is linked to a campaign: _get_fund_campaign_id on the team post.
  • An individual page is linked to a campaign and/or team: _get_fund_campaign_id and _get_fund_team_id on the page.

This means campaigns, teams, and pages can exist independently. A team does not need a campaign; a page does not need a team.

P2p hierarchy diagram

How to use it

Setting up a campaign

  1. Go to Fundations > Campaigns (or create a new get_fund_action and mark it as a campaign from the admin meta box).
  2. Give the campaign a title, description, and goal.
  3. Publish it.
  4. Share the campaign URL with your participants so they can join using the Action Wizard.

Joining a campaign as an individual

  1. A supporter opens the Action Wizard on your site.
  2. They select Individual as their structure type and choose the campaign from the list.
  3. They complete the wizard. Their page is linked to the campaign.

Joining a campaign as part of a team

  1. A supporter opens the Action Wizard.
  2. They select Join a Team.
  3. They search for and select an existing team.
  4. They complete the wizard. Their page is linked to both the team and the campaign.

Creating a new team

  1. A supporter opens the Action Wizard.
  2. They select Create a Team.
  3. They enter a team name and description.
  4. They complete the wizard. A new get_fund_team post is created and their page is linked to it.
Wizard team selection

Disabling new participants on a campaign

  1. Open the edit form for the campaign (as author or admin).
  2. Toggle Disable new participants on.
  3. Save.

Once enabled, the wizard will block new pages from joining that campaign. Non-admin fundraisers can enable this setting but cannot disable it once set. Only admins can re-enable joining from the WordPress admin.

Settings & options

There are no dedicated settings panel options for teams. Team behaviour is controlled by meta on each post.

Meta keyPost typeDescription
_get_fund_is_campaignget_fund_actionMarks this action as a campaign (parent)
_get_fund_children_disabledget_fund_actionWhen true, no new pages can join this campaign
_get_fund_campaign_idget_fund_action, get_fund_teamLinks this post to its parent campaign
_get_fund_team_idget_fund_actionLinks this page to a team
_get_fund_structure_typeget_fund_actionindividual, join_team, or create_team
_get_fund_team_goalget_fund_teamThe team’s fundraising goal
_get_fund_team_raisedget_fund_teamThe team’s total raised amount
_get_fund_creator_idget_fund_teamThe user who created the team

What you can and cannot do

You can:

  • Create campaigns with any number of child pages and teams.
  • Allow supporters to create their own teams through the wizard.
  • Prevent new participants from joining a campaign at any time.
  • Display campaign and team progress using Fundations blocks on any page.
  • Create standalone teams not linked to any campaign.

You cannot:

  • Move an individual page from one campaign to another through the frontend (requires admin intervention).
  • Merge two campaigns.
  • Display nested sub-teams (the hierarchy is flat: campaign > team > page).
  • Re-enable participant joining on a campaign from the frontend (admin only).

Examples

A charity creates one campaign called “Annual 5K Run”. Participants use the wizard to create individual pages. Each class or group creates a team. The charity displays campaign-level totals on the main page and team totals on sub-pages.

For a school fundraiser, a school creates a campaign and each class creates a team during registration. Students join their class team. Teachers and parents can see totals by class and by individual student.

Troubleshooting

ProblemLikely causeFix
“This campaign is not accepting new supporters”_get_fund_children_disabled is set on the campaignAsk the admin to re-enable joining from the WordPress admin
A team does not appear in the wizard searchThe team is not linked to the campaign selected in the wizardCheck that _get_fund_campaign_id on the team matches the campaign being searched
A fundraising page is not appearing under the correct campaign_get_fund_campaign_id is missing or wrongCheck and correct the meta value from the WordPress admin
Team totals are not updatingStats recalculate on get_fund_donation_paid; payments may be pendingVerify payment status and webhook delivery

Developer reference

Team search AJAX

The wizard searches for teams via AJAX action get_fund_search_teams. It accepts:

ParameterDescription
searchSearch term
campaign_idOptional campaign ID to filter teams by campaign

Returned data per team: id, title, description, member_count, goal, raised.

Key hooks

The team and campaign system uses the same hooks as standard fundraising pages:

HookTypeDescription
get_fund_action_createdactionFires after any fundraising page (including team-linked pages) is created
get_fund_wizard_post_datafilterModify wp_insert_post args during creation, including for get_fund_team posts
get_fund_wizard_meta_valuesfilterModify meta values on newly created pages; includes _get_fund_team_id and _get_fund_campaign_id
get_fund_wizard_campaign_query_argsfilterModify the campaign search query in the wizard

Querying child pages

// Get all pages linked to a campaign
$args = array(
    'post_type'  => 'get_fund_action',
    'meta_query' => array(
        array(
            'key'   => '_get_fund_campaign_id',
            'value' => $campaign_id,
        ),
    ),
);
$pages = new WP_Query( $args );

// Get all pages in a specific team
$args = array(
    'post_type'  => 'get_fund_action',
    'meta_query' => array(
        array(
            'key'   => '_get_fund_team_id',
            'value' => $team_id,
        ),
    ),
);
$team_pages = new WP_Query( $args );