Add Email Tag For Donation Field
/** * If you want to add an email tag for an existing donation field, * you can use the code sample below. * * To add a completely custom email tag field, you can either register * a field…Continue reading
Join 2,000,000+ Professionals who use WPCode to Future-Proof Their Websites!
/** * If you want to add an email tag for an existing donation field, * you can use the code sample below. * * To add a completely custom email tag field, you can either register * a field…Continue reading
/** * This example shows how to change the output of the line items * displayed by the donation summary in email receipts. In this example, * we simply display the total amount donated on each line. * * @param…Continue reading
/** * This example shows how you can add a new campaign field to be displayed * in Charitable emails related to campaigns. */ /** * Register the extra field. * * @param array $fields * @param Charitable_Email $email *…Continue reading
/** * This example shows how to remove fields from the donation form. * * Note that this approach requires Charitable 1.6 or above. */ add_action( ‘init’, function() { $fields_api = charitable()->donation_fields(); /** * In this example, we remove the…Continue reading
/** * Change the “Postcode” field into a “ZIP Code” field. * * @param array[] $fields * @return array[] */ add_action( ‘init’, function ( $fields ) { $fields = charitable()->donation_fields(); $field = $fields->get_field( ‘postcode’ ); $field->label = ‘ZIP Code’; $field->set(…Continue reading
/** * The `charitable_login_form_args` filter allows you to set * the arguments that are passed to wp_login_form(). * * In this example, we change the URL that people are redirected * to after logging in through the form generated by…Continue reading
/** * Right after a donation is made, this sends the donation receipt to * the donor if the donation is pending AND it was made in offline mode. * * @param int $donation_id * @return boolean */ function en_send_donation_receipt_for_pending_offline(…Continue reading
/** * By default, the Donors widget & shortcode will only include donors with * Paid donations. With this snippet, you can make sure that * donors with Pending donations are also included. */ function ed_include_pending_donors_in_donors_widget_shortcode( $query_args ) { $query_args[‘status’]…Continue reading
/** * Filter the email footer text & link. * * @param string $text The default text. * @return string */ function ed_charitable_change_email_footer_text( $text ) { $text = ‘Your footer text’; $link = home_url(); return ‘‘ . $text . ‘Continue reading
/** * Change the donors widget so only the first name and last name * initial of the donor are shown. * * @param string $name The name to be displayed * @param array $args Arguments passed to the donor-loop/donor.php…Continue reading