PluginProbe
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) / 1.6.9
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) v1.6.9
1.8.12.3 1.8.12.2 1.8.12.1 1.8.12 1.8.11.3 1.8.11.2 1.8.11.1 1.8.11 1.6.6 1.6.60 1.6.7 1.6.8 1.6.9 1.7.0 1.7.0.1 1.7.0.11 1.7.0.12 1.7.0.14 1.7.0.2 1.7.0.3 1.7.0.5 1.7.0.6 1.7.0.7 1.7.0.9 1.8.0 All 210 releases
charitable / templates / campaign-loop.php

campaign-loop.php in Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) 1.6.9, at templates/campaign-loop.php

61 lines 1.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Displays the campaign loop.
4 *
5 * Override this template by copying it to yourtheme/charitable/campaign-loop.php
6 *
7 * @author Studio 164a
8 * @package Charitable/Templates/Campaign
9 * @since 1.0.0
10 * @version 1.5.7
11 */
12
13 // Exit if accessed directly.
14 if ( ! defined( 'ABSPATH' ) ) { exit; }
15
16 $campaigns = $view_args['campaigns'];
17
18 if ( ! $campaigns->have_posts() ) :
19 return;
20 endif;
21
22 $loop_class = charitable_campaign_loop_class( $view_args );
23 $args = charitable_campaign_loop_args( $view_args );
24
25 /**
26 * Add something before the campaign loop.
27 *
28 * @since 1.5.0
29 *
30 * @param WP_Query $campaigns The campaigns.
31 * @param array $args Loop args.
32 */
33 do_action( 'charitable_campaign_loop_before', $campaigns, $args );
34
35 ?>
36 <ol class="<?php echo esc_attr( $loop_class ); ?>">
37
38 <?php
39 while ( $campaigns->have_posts() ) :
40
41 $campaigns->the_post();
42
43 charitable_template( 'campaign-loop/campaign.php', $args );
44
45 endwhile;
46
47 wp_reset_postdata();
48 ?>
49 </ol>
50 <?php
51
52 /**
53 * Add something after the campaign loop.
54 *
55 * @since 1.5.0
56 *
57 * @param WP_Query $campaigns The campaigns.
58 * @param array $args Loop args.
59 */
60 do_action( 'charitable_campaign_loop_after', $campaigns, $args );
61