Plugin Directory

Changeset 2424002


Ignore:
Timestamp:
11/23/2020 11:26:56 PM (5 years ago)
Author:
brewlabs
Message:

Update for new WordPress

Location:
wp-email-delivery/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • wp-email-delivery/trunk/includes/class-wp-email-delivery-settings.php

    r1817806 r2424002  
    8080         
    8181          foreach ($options as $option) {
    82             if (isset($_POST[$option])) {
     82            if (!empty($_POST[$option])) {
    8383              // If we registered a callback function to sanitizes the option's
    8484              // value it is where we call it (see register_setting).
    85               $option_value = apply_filters('sanitize_option_' . $option_name, $_POST[$option]);
     85              $option_value = apply_filters('sanitize_option_' . $option, $_POST[$option]);
    8686              // And finally we save our option with the site's options.
    8787              update_site_option($option, $option_value);
     
    392392    private function send_test_email(){
    393393        $headers = array('Content-type: text/html');
    394         $this->parent->connections->mail( $_POST[ $this->base .'test_email' ], "WP Email Delivery Setup Test", wped_basic_test_email(), $headers, "");
     394        $this->parent->connections->mail( sanitize_email($_POST[ $this->base .'test_email' ]), "WP Email Delivery Setup Test", wped_basic_test_email(), $headers, "");
    395395    }
    396396
     
    404404            // Check posted/selected tab
    405405            $current_section = '';
    406             if ( isset( $_POST['tab'] ) && $_POST['tab'] ) {
    407                 $current_section = $_POST['tab'];
     406            if (!empty( $_POST['tab'] )) {
     407                $current_section = sanitize_title_with_dashes($_POST['tab']);
    408408            } else {
    409                 if ( isset( $_GET['tab'] ) && $_GET['tab'] ) {
    410                     $current_section = $_GET['tab'];
     409                if ( !empty( $_GET['tab'] ) ) {
     410                    $current_section = sanitize_title_with_dashes($_GET['tab']);
    411411                }
    412412            }
    413413
    414             if(isset( $_POST[ $this->base .'test_email' ] )){
     414            if(!empty( $_POST[ $this->base .'test_email' ] )){
    415415                $this->send_test_email();   
    416416            }
     
    468468            }
    469469            $tab = '';
    470             if ( isset( $_GET['tab'] ) && $_GET['tab'] ) {
    471                 $tab .= $_GET['tab'];
     470            if ( !empty( $_GET['tab'] ) ) {
     471                $tab .= sanitize_title_with_dashes($_GET['tab']);
    472472            }
    473473
     
    482482                    // Set tab class
    483483                    $class = 'nav-tab';
    484                     if ( ! isset( $_GET['tab'] ) ) {
     484                    if ( empty( $_GET['tab'] ) ) {
    485485                        if ( 0 == $c ) {
    486486                            $class .= ' nav-tab-active';
     
    489489                        }
    490490                    } else {
    491                         if ( isset( $_GET['tab'] ) && $section == $_GET['tab'] ) {
     491                        if ( !empty( $_GET['tab'] ) && $section == sanitize_title_with_dashes($_GET['tab']) ) {
    492492                            $class .= ' nav-tab-active';
    493493                            $button_text = isset( $data['custom_save'] ) ? $data['custom_save'] : esc_attr( __( 'Save Settings' , 'wp-email-delivery' ) ) ;
     
    498498                    // Set tab link
    499499                    $tab_link = add_query_arg( array( 'tab' => $section ) );
    500                     if ( isset( $_GET['settings-updated'] ) ) {
     500                    if ( !empty( $_GET['settings-updated'] ) ) {
    501501                        $tab_link = remove_query_arg( 'settings-updated', $tab_link );
    502502                    }
  • wp-email-delivery/trunk/readme.txt

    r1817806 r2424002  
    44Tags: newsletter, newsletters, manager newsletter, newsletter signup, newsletter widget, subscribers, subscription, email marketing, email, emailing, smtp, sendpress, sendgrid, mandrill, mailchimp
    55Requires at least: 3.7
    6 Tested up to: 4.9.1
    7 Stable tag: 1.1.2.7
     6Tested up to: 5.6
     7Stable tag: 1.20.11.23
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    5757== Changelog ==
    5858
     59= 1.20.11.23 - 2020.11.23 =
     60* Update: code base update for new wordpress versions
     61
    5962= 1.1.2.7 - 2018.2.7 =
    6063* Update: add sending email override settings
  • wp-email-delivery/trunk/wp-email-delivery.php

    r1817806 r2424002  
    77Author URI: https://www.wpemaildelivery.com/
    88Requires at least: 3.7
    9 Tested up to: 4.9.1
    10 Version: 1.1.2.7
     9Tested up to: 5.6
     10Version: 1.20.11.23
    1111
    1212Text Domain: wp-email-delivery
     
    4545 */
    4646function WPED () {
    47     return WP_Email_Delivery::instance( __FILE__, '1.1.2.7' );
     47    return WP_Email_Delivery::instance( __FILE__, '1.20.11.23' );
    4848}
    4949WPED();
Note: See TracChangeset for help on using the changeset viewer.