@@ -8,7 +8,7 @@ discard block |
||
| 8 | 8 | * @version 1.0 |
| 9 | 9 | */ |
| 10 | 10 | |
| 11 | -if ( ! defined( 'ABSPATH' ) ) { |
|
| 11 | +if ( ! defined('ABSPATH')) { |
|
| 12 | 12 | exit; // Exit if accessed directly. |
| 13 | 13 | } |
| 14 | 14 | |
@@ -19,9 +19,9 @@ discard block |
||
| 19 | 19 | * |
| 20 | 20 | * @since 1.0 |
| 21 | 21 | */ |
| 22 | -do_action( 'give_before_single_form' ); |
|
| 22 | +do_action('give_before_single_form'); |
|
| 23 | 23 | |
| 24 | -if ( post_password_required() ) { |
|
| 24 | +if (post_password_required()) { |
|
| 25 | 25 | echo get_the_password_form(); |
| 26 | 26 | return; |
| 27 | 27 | } |
@@ -37,10 +37,10 @@ discard block |
||
| 37 | 37 | * |
| 38 | 38 | * @since 1.0 |
| 39 | 39 | */ |
| 40 | - do_action( 'give_before_single_form_summary' ); |
|
| 40 | + do_action('give_before_single_form_summary'); |
|
| 41 | 41 | ?> |
| 42 | 42 | |
| 43 | - <div class="<?php echo apply_filters( 'give_forms_single_summary_classes', 'summary entry-summary' ); ?>"> |
|
| 43 | + <div class="<?php echo apply_filters('give_forms_single_summary_classes', 'summary entry-summary'); ?>"> |
|
| 44 | 44 | |
| 45 | 45 | <?php |
| 46 | 46 | /** |
@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | * |
| 51 | 51 | * @since 1.0 |
| 52 | 52 | */ |
| 53 | - do_action( 'give_single_form_summary' ); |
|
| 53 | + do_action('give_single_form_summary'); |
|
| 54 | 54 | ?> |
| 55 | 55 | |
| 56 | 56 | </div> |
@@ -64,7 +64,7 @@ discard block |
||
| 64 | 64 | * |
| 65 | 65 | * @since 1.0 |
| 66 | 66 | */ |
| 67 | - do_action( 'give_after_single_form_summary' ); |
|
| 67 | + do_action('give_after_single_form_summary'); |
|
| 68 | 68 | ?> |
| 69 | 69 | |
| 70 | 70 | </div><!-- #give-form-<?php the_ID(); ?> --> |
@@ -77,5 +77,5 @@ discard block |
||
| 77 | 77 | * |
| 78 | 78 | * @since 1.0 |
| 79 | 79 | */ |
| 80 | -do_action( 'give_after_single_form' ); |
|
| 80 | +do_action('give_after_single_form'); |
|
| 81 | 81 | ?> |
@@ -11,7 +11,7 @@ |
||
| 11 | 11 | * @since 1.0 |
| 12 | 12 | */ |
| 13 | 13 | |
| 14 | -if ( ! defined( 'ABSPATH' ) ) {
|
|
| 14 | +if ( ! defined('ABSPATH')) {
|
|
| 15 | 15 | exit; // Exit if accessed directly. |
| 16 | 16 | } ?> |
| 17 | 17 | <h1 itemprop="name" class="give-form-title entry-title"><?php the_title(); ?></h1> |
@@ -5,11 +5,11 @@ |
||
| 5 | 5 | ?> |
| 6 | 6 | <div id="give-payment-processing"> |
| 7 | 7 | <?php |
| 8 | - Give()->notices->print_frontend_notice( sprintf( |
|
| 8 | + Give()->notices->print_frontend_notice(sprintf( |
|
| 9 | 9 | /* translators: %s: success page URL */ |
| 10 | - __( 'Your donation is processing. This page will reload automatically in 8 seconds. If it does not, click <a href="%s">here</a>.', 'give' ), |
|
| 10 | + __('Your donation is processing. This page will reload automatically in 8 seconds. If it does not, click <a href="%s">here</a>.', 'give'), |
|
| 11 | 11 | give_get_success_page_uri() |
| 12 | - ), true, 'success' ); |
|
| 12 | + ), true, 'success'); |
|
| 13 | 13 | ?> |
| 14 | 14 | <span class="give-loading-animation"></span> |
| 15 | 15 | <script type="text/javascript">setTimeout(function () { |
@@ -6,13 +6,13 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined('ABSPATH')) exit; // Exit if accessed directly. |
|
| 10 | 10 | // This is the footer used if no others are available |
| 11 | 11 | ?> |
| 12 | 12 | <!DOCTYPE html> |
| 13 | 13 | <html> |
| 14 | 14 | <head> |
| 15 | 15 | <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> |
| 16 | - <title><?php echo get_bloginfo( 'name' ); ?></title> |
|
| 16 | + <title><?php echo get_bloginfo('name'); ?></title> |
|
| 17 | 17 | </head> |
| 18 | 18 | <body> |
| 19 | 19 | \ No newline at end of file |
@@ -6,7 +6,10 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined( 'ABSPATH' ) ) { |
|
| 10 | + exit; |
|
| 11 | +} |
|
| 12 | +// Exit if accessed directly. |
|
| 10 | 13 | // This is the footer used if no others are available |
| 11 | 14 | ?> |
| 12 | 15 | <!DOCTYPE html> |
@@ -6,7 +6,7 @@ discard block |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined('ABSPATH')) exit; // Exit if accessed directly. |
|
| 10 | 10 | |
| 11 | 11 | |
| 12 | 12 | // For gmail compatibility, including CSS styles in head/body are stripped out therefore styles need to be inline. These variables contain rules which are added to the template inline. |
@@ -44,7 +44,7 @@ discard block |
||
| 44 | 44 | <table border="0" cellpadding="10" cellspacing="0" width="100%"> |
| 45 | 45 | <tr> |
| 46 | 46 | <td colspan="2" valign="middle" id="credit" style="<?php echo $credit; ?>"> |
| 47 | - <?php echo wpautop( wp_kses_post( wptexturize( apply_filters( 'give_email_footer_text', '<a href="' . esc_url( home_url() ) . '">' . get_bloginfo( 'name' ) . '</a>' ) ) ) ); ?> |
|
| 47 | + <?php echo wpautop(wp_kses_post(wptexturize(apply_filters('give_email_footer_text', '<a href="'.esc_url(home_url()).'">'.get_bloginfo('name').'</a>')))); ?> |
|
| 48 | 48 | </td> |
| 49 | 49 | </tr> |
| 50 | 50 | </table> |
@@ -6,7 +6,10 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined( 'ABSPATH' ) ) { |
|
| 10 | + exit; |
|
| 11 | +} |
|
| 12 | +// Exit if accessed directly. |
|
| 10 | 13 | |
| 11 | 14 | |
| 12 | 15 | // For gmail compatibility, including CSS styles in head/body are stripped out therefore styles need to be inline. These variables contain rules which are added to the template inline. |
@@ -6,7 +6,7 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined('ABSPATH')) exit; // Exit if accessed directly. |
|
| 10 | 10 | |
| 11 | 11 | // {email} is replaced by the content entered in Donations > Settings > Emails |
| 12 | 12 | |
@@ -6,7 +6,10 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined( 'ABSPATH' ) ) { |
|
| 10 | + exit; |
|
| 11 | +} |
|
| 12 | +// Exit if accessed directly. |
|
| 10 | 13 | |
| 11 | 14 | // {email} is replaced by the content entered in Donations > Settings > Emails |
| 12 | 15 | |
@@ -6,7 +6,7 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined('ABSPATH')) exit; // Exit if accessed directly. |
|
| 10 | 10 | |
| 11 | 11 | // This is the footer used if no others are available |
| 12 | 12 | |
@@ -6,7 +6,10 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined( 'ABSPATH' ) ) { |
|
| 10 | + exit; |
|
| 11 | +} |
|
| 12 | +// Exit if accessed directly. |
|
| 10 | 13 | |
| 11 | 14 | // This is the footer used if no others are available |
| 12 | 15 | |
@@ -6,7 +6,7 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined('ABSPATH')) exit; // Exit if accessed directly. |
|
| 10 | 10 | |
| 11 | 11 | // {email} is replaced by the content entered in Donations > Settings > Emails |
| 12 | 12 | |
@@ -6,7 +6,10 @@ |
||
| 6 | 6 | * @version 1.0 |
| 7 | 7 | */ |
| 8 | 8 | |
| 9 | -if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly. |
|
| 9 | +if ( ! defined( 'ABSPATH' ) ) { |
|
| 10 | + exit; |
|
| 11 | +} |
|
| 12 | +// Exit if accessed directly. |
|
| 10 | 13 | |
| 11 | 14 | // {email} is replaced by the content entered in Donations > Settings > Emails |
| 12 | 15 | |
@@ -39,8 +39,8 @@ |
||
| 39 | 39 | } |
| 40 | 40 | |
| 41 | 41 | if ( ( is_plugin_active( 'wordpress-seo/wp-seo.php' ) |
| 42 | - || is_plugin_active( 'wordpress-seo-premium/wp-seo-premium.php' ) ) |
|
| 43 | - && class_exists( 'WPSEO_Sitemaps_Cache' ) |
|
| 42 | + || is_plugin_active( 'wordpress-seo-premium/wp-seo-premium.php' ) ) |
|
| 43 | + && class_exists( 'WPSEO_Sitemaps_Cache' ) |
|
| 44 | 44 | ) { |
| 45 | 45 | |
| 46 | 46 | $forms_singular_option = give_get_option( 'forms_singular' ); |
@@ -19,10 +19,10 @@ discard block |
||
| 19 | 19 | * @return void |
| 20 | 20 | */ |
| 21 | 21 | function give_disable_mandrill_nl2br() { |
| 22 | - add_filter( 'mandrill_nl2br', '__return_false' ); |
|
| 22 | + add_filter('mandrill_nl2br', '__return_false'); |
|
| 23 | 23 | } |
| 24 | 24 | |
| 25 | -add_action( 'give_email_send_before', 'give_disable_mandrill_nl2br' ); |
|
| 25 | +add_action('give_email_send_before', 'give_disable_mandrill_nl2br'); |
|
| 26 | 26 | |
| 27 | 27 | |
| 28 | 28 | /** |
@@ -34,33 +34,33 @@ discard block |
||
| 34 | 34 | */ |
| 35 | 35 | function give_clear_seo_sitemap_cache_on_settings_change() { |
| 36 | 36 | // Load required file if the fn 'is_plugin_active' doesn't exists. |
| 37 | - if ( ! function_exists( 'is_plugin_active' ) ) { |
|
| 38 | - require_once ABSPATH . 'wp-admin/includes/plugin.php'; |
|
| 37 | + if ( ! function_exists('is_plugin_active')) { |
|
| 38 | + require_once ABSPATH.'wp-admin/includes/plugin.php'; |
|
| 39 | 39 | } |
| 40 | 40 | |
| 41 | - if ( ( is_plugin_active( 'wordpress-seo/wp-seo.php' ) |
|
| 42 | - || is_plugin_active( 'wordpress-seo-premium/wp-seo-premium.php' ) ) |
|
| 43 | - && class_exists( 'WPSEO_Sitemaps_Cache' ) |
|
| 41 | + if ((is_plugin_active('wordpress-seo/wp-seo.php') |
|
| 42 | + || is_plugin_active('wordpress-seo-premium/wp-seo-premium.php')) |
|
| 43 | + && class_exists('WPSEO_Sitemaps_Cache') |
|
| 44 | 44 | ) { |
| 45 | 45 | |
| 46 | - $forms_singular_option = give_get_option( 'forms_singular' ); |
|
| 47 | - $forms_archive_option = give_get_option( 'forms_singular' ); |
|
| 46 | + $forms_singular_option = give_get_option('forms_singular'); |
|
| 47 | + $forms_archive_option = give_get_option('forms_singular'); |
|
| 48 | 48 | |
| 49 | 49 | // If there is change detected for Single Form View and Form Archives options then proceed. |
| 50 | 50 | if ( |
| 51 | - ( isset( $_POST['forms_singular'] ) && $_POST['forms_singular'] !== $forms_singular_option ) || |
|
| 52 | - ( isset( $_POST['forms_archives'] ) && $_POST['forms_archives'] !== $forms_archive_option ) |
|
| 51 | + (isset($_POST['forms_singular']) && $_POST['forms_singular'] !== $forms_singular_option) || |
|
| 52 | + (isset($_POST['forms_archives']) && $_POST['forms_archives'] !== $forms_archive_option) |
|
| 53 | 53 | ) { |
| 54 | 54 | // If Yoast SEO or Yoast SEO Premium plugin exists, then update seo sitemap cache. |
| 55 | 55 | $yoast_sitemaps_cache = new WPSEO_Sitemaps_Cache(); |
| 56 | - if ( method_exists( $yoast_sitemaps_cache, 'clear' ) ) { |
|
| 56 | + if (method_exists($yoast_sitemaps_cache, 'clear')) { |
|
| 57 | 57 | WPSEO_Sitemaps_Cache::clear(); |
| 58 | 58 | } |
| 59 | 59 | } |
| 60 | 60 | } |
| 61 | 61 | } |
| 62 | 62 | |
| 63 | -add_action( 'give-settings_save_display', 'give_clear_seo_sitemap_cache_on_settings_change' ); |
|
| 63 | +add_action('give-settings_save_display', 'give_clear_seo_sitemap_cache_on_settings_change'); |
|
| 64 | 64 | |
| 65 | 65 | /** |
| 66 | 66 | * This is support for the plugin Elementor. This function |
@@ -78,12 +78,12 @@ discard block |
||
| 78 | 78 | /** |
| 79 | 79 | * Is the plugin: Elementor activated? |
| 80 | 80 | */ |
| 81 | - if ( is_plugin_active( 'elementor/elementor.php' ) ) { |
|
| 81 | + if (is_plugin_active('elementor/elementor.php')) { |
|
| 82 | 82 | |
| 83 | 83 | /** |
| 84 | 84 | * Check user is on the Elementor's editor page, then hide Give Shortcodes Button. |
| 85 | 85 | */ |
| 86 | - if ( isset( $_GET['action'] ) && 'elementor' === give_clean( $_GET['action'] ) ) { |
|
| 86 | + if (isset($_GET['action']) && 'elementor' === give_clean($_GET['action'])) { |
|
| 87 | 87 | return false; |
| 88 | 88 | } |
| 89 | 89 | } |
@@ -91,4 +91,4 @@ discard block |
||
| 91 | 91 | return true; |
| 92 | 92 | } |
| 93 | 93 | |
| 94 | -add_filter( 'give_shortcode_button_condition', 'give_elementor_hide_shortcodes_button', 11 ); |
|
| 94 | +add_filter('give_shortcode_button_condition', 'give_elementor_hide_shortcodes_button', 11); |
|