| @@ -3,16 +3,19 @@ | ||
| 3 | 3 | * Displays the campaign donation form. |
| 4 | 4 | * |
| 5 | 5 | * Override this template by copying it to yourtheme/charitable/content-donation-form.php |
| 6 | 6 | * |
| 7 | - * @author Studio 164a | |
| 7 | + * @author WP Charitable LLC | |
| 8 | 8 | * @package Charitable/Templates/Campaign |
| 9 | 9 | * @since 1.0.0 |
| 10 | 10 | * @version 1.0.0 |
| 11 | + * @version 1.8.8.6 | |
| 11 | 12 | */ |
| 12 | 13 | |
| 13 | 14 | // Exit if accessed directly. |
| 14 | -if ( ! defined( 'ABSPATH' ) ) { exit; } | |
| 15 | +if ( ! defined( 'ABSPATH' ) ) { | |
| 16 | + exit; | |
| 17 | +} | |
| 15 | 18 | |
| 16 | 19 | /** |
| 17 | 20 | * The donation form object used for donations to this campaign. By |
| 18 | 21 | * default, this will be a Charitable_Donation_Form object, but |
| @@ -20,24 +23,34 @@ | ||
| 20 | 23 | * instead. |
| 21 | 24 | * |
| 22 | 25 | * @var Charitable_Donation_Form_Interface |
| 23 | 26 | */ |
| 24 | -$form = charitable_get_current_donation_form(); | |
| 27 | +$charitable_form = charitable_get_current_donation_form(); | |
| 25 | 28 | |
| 26 | -if ( ! $form ) { | |
| 29 | +if ( ! $charitable_form ) { | |
| 27 | 30 | return; |
| 28 | 31 | } |
| 29 | 32 | |
| 30 | 33 | /** |
| 31 | - * @hook charitable_donation_form_before | |
| 34 | + * Add something before the donation form. | |
| 35 | + * | |
| 36 | + * @hook charitable_donation_form_before | |
| 37 | + * | |
| 38 | + * @param Charitable_Donation_Form_Interface $form The donation form object. | |
| 32 | 39 | */ |
| 33 | -do_action( 'charitable_donation_form_before', $form ); | |
| 40 | +do_action( 'charitable_donation_form_before', $charitable_form ); | |
| 34 | 41 | |
| 35 | 42 | /** |
| 36 | 43 | * Render the donation form. |
| 44 | + * | |
| 45 | + * @param Charitable_Donation_Form_Interface $form The donation form object. | |
| 37 | 46 | */ |
| 38 | -$form->render(); | |
| 47 | +$charitable_form->render(); | |
| 39 | 48 | |
| 40 | 49 | /** |
| 41 | - * @hook charitable_donation_form_after | |
| 50 | + * Add something after the donation form. | |
| 51 | + * | |
| 52 | + * @hook charitable_donation_form_after | |
| 53 | + * | |
| 54 | + * @param Charitable_Donation_Form_Interface $form The donation form object. | |
| 42 | 55 | */ |
| 43 | -do_action( 'charitable_donation_form_after', $form ); | |
| 56 | +do_action( 'charitable_donation_form_after', $charitable_form ); | |