| 1 |
<?php |
| 2 |
/** |
| 3 |
* The template for displaying campaign content within loops. |
| 4 |
* |
| 5 |
* Override this template by copying it to yourtheme/charitable/campaign-loop/campaign.php |
| 6 |
* |
| 7 |
* @author WP Charitable LLC |
| 8 |
* @package Charitable/Templates/Campaign |
| 9 |
* @since 1.0.0 |
| 10 |
* @version 1.0.0 |
| 11 |
* @version 1.8.8.6 |
| 12 |
*/ |
| 13 |
|
| 14 |
// Exit if accessed directly. |
| 15 |
if ( ! defined( 'ABSPATH' ) ) { |
| 16 |
exit; |
| 17 |
} |
| 18 |
|
| 19 |
$charitable_campaign = charitable_get_current_campaign(); |
| 20 |
|
| 21 |
?> |
| 22 |
<li id="campaign-<?php echo esc_attr( get_the_ID() ); ?>" <?php post_class(); ?>> |
| 23 |
<?php |
| 24 |
/** |
| 25 |
* Hook: Before campaign content loop. |
| 26 |
* |
| 27 |
* @hook charitable_campaign_content_loop_before |
| 28 |
*/ |
| 29 |
do_action( 'charitable_campaign_content_loop_before', $charitable_campaign, $view_args ); |
| 30 |
|
| 31 |
?> |
| 32 |
<a href="<?php the_permalink(); ?>"> |
| 33 |
<?php |
| 34 |
/** |
| 35 |
* Hook: Before campaign content loop title. |
| 36 |
* |
| 37 |
* @hook charitable_campaign_content_loop_before_title |
| 38 |
*/ |
| 39 |
do_action( 'charitable_campaign_content_loop_before_title', $charitable_campaign, $view_args ); |
| 40 |
?> |
| 41 |
|
| 42 |
<h3><?php the_title(); ?></h3> |
| 43 |
|
| 44 |
<?php |
| 45 |
/** |
| 46 |
* Hook: After campaign content loop title. |
| 47 |
* |
| 48 |
* @hook charitable_campaign_content_loop_after_title |
| 49 |
*/ |
| 50 |
do_action( 'charitable_campaign_content_loop_after_title', $charitable_campaign, $view_args ); |
| 51 |
?> |
| 52 |
</a> |
| 53 |
<?php |
| 54 |
|
| 55 |
/** |
| 56 |
* Hook: After campaign content loop. |
| 57 |
* |
| 58 |
* @hook charitable_campaign_content_loop_after |
| 59 |
*/ |
| 60 |
do_action( 'charitable_campaign_content_loop_after', $charitable_campaign, $view_args ); |
| 61 |
?> |
| 62 |
</li> |
| 63 |
|