Plugin Directory

Changeset 2695255


Ignore:
Timestamp:
03/17/2022 08:34:43 AM (4 years ago)
Author:
Sygnoos
Message:

New version 4.1.3 released

Location:
popup-builder
Files:
359 added
5 edited

Legend:

Unmodified
Added
Removed
  • popup-builder/trunk/com/classes/Actions.php

    r2688779 r2695255  
    793793        $subscribers = apply_filters('sgpNewsletterSendingSubscribers', $subscribers);
    794794
    795         $blogInfo = get_bloginfo();
     795        $blogInfo = wp_specialchars_decode( get_bloginfo() );
    796796        $headers = array(
    797797            'From: "'.$blogInfo.'" <'.$fromEmail.'>' ,
  • popup-builder/trunk/com/config/configPackage.php

    r2688779 r2695255  
    44}
    55
    6 define('SG_POPUP_VERSION', '4.1.2');
     6define('SG_POPUP_VERSION', '4.1.3');
    77define('SGPB_POPUP_PKG', SGPB_POPUP_PKG_FREE);
    88define('POPUP_BUILDER_BASENAME', 'popupbuilder-platinum/popup-builder.php');
  • popup-builder/trunk/com/helpers/AdminHelper.php

    r2688779 r2695255  
    11971197        $contentType = 'text/html';
    11981198        $charset = 'UTF-8';
    1199         $blogInfo = get_bloginfo();
     1199        $blogInfo = wp_specialchars_decode( get_bloginfo() );
    12001200
    12011201        if (!empty($args['contentType'])) {
     
    20542054        $fromEmail = $newsletterData['fromEmail'];
    20552055        $emailMessage = $newsletterData['messageBody'];
    2056         $blogInfo = get_bloginfo();
     2056        $blogInfo = wp_specialchars_decode( get_option( 'blogname' ) );
    20572057        $headers = array(
    20582058            'From: "'.$blogInfo.'" <'.$fromEmail.'>' ,
     
    20762076        }
    20772077
    2078         $mailStatus = wp_mail($emails, $mailSubject, $emailMessage, $headers);
     2078        $newsletterOptions = get_option('SGPB_NEWSLETTER_DATA');
     2079        $allAvailableShortcodes = array();
     2080        $allAvailableShortcodes['patternBlogName'] = '/\[Blog name]/';
     2081        $allAvailableShortcodes['patternUserName'] = '/\[User name]/';
     2082        $allAvailableShortcodes['patternUnsubscribe'] = '';
     2083
     2084        $pattern = "/\[(\[?)(Unsubscribe)(?![\w-])([^\]\/]*(?:\/(?!\])[^\]\/]*)*?)(?:(\/)\]|\](?:([^\[]\*+(?:\[(?!\/\2\])[^\[]\*+)\*+)\[\/\2\])?)(\]?)/";
     2085        preg_match($pattern, $emailMessage, $matches);
     2086        $title = __('Unsubscribe', SG_POPUP_TEXT_DOMAIN);
     2087        if ($matches) {
     2088            $patternUnsubscribe = $matches[0];
     2089            // If user didn't change anything inside the [unsubscribe] shortcode $matches[2] will be equal to 'Unsubscribe'
     2090            if ($matches[2] == 'Unsubscribe') {
     2091                $pattern = '/\s(\w+?)="(.+?)"]/';
     2092                preg_match($pattern, $matches[0], $matchesTitle);
     2093                if (!empty($matchesTitle[2])) {
     2094                    $title = AdminHelper::removeAllNonPrintableCharacters($matchesTitle[2], 'Unsubscribe');
     2095                }
     2096            }
     2097            $allAvailableShortcodes['patternUnsubscribe'] = $patternUnsubscribe;
     2098        }
     2099
     2100        $emailMessageCustom = preg_replace($allAvailableShortcodes['patternBlogName'], $newsletterOptions['blogname'], $emailMessage);
     2101        $emailMessageCustom = preg_replace($allAvailableShortcodes['patternUserName'], $newsletterOptions['username'], $emailMessageCustom);
     2102        $emailMessageCustom = str_replace($allAvailableShortcodes['patternUnsubscribe'], '', $emailMessageCustom);
     2103
     2104        $mailStatus = wp_mail($emails, $mailSubject, $emailMessageCustom, $headers);
    20792105
    20802106        wp_die(esc_html($newsletterData['testSendingStatus']));
  • popup-builder/trunk/popup-builder.php

    r2688779 r2695255  
    44* Plugin URI: https://popup-builder.com
    55* Description: The most complete popup plugin. Html, image, iframe, shortcode, video and many other popup types. Manage popup dimensions, effects, themes and more.
    6 * Version: 4.1.2
     6* Version: 4.1.3
    77* Author: Sygnoos
    88* Author URI: https://sygnoos.com
  • popup-builder/trunk/readme.txt

    r2688779 r2695255  
    99Tested up to: 5.9
    1010Requires PHP: 5.3.3
    11 Stable tag: 4.1.2
     11Stable tag: 4.1.3
    1212License: GPLv2 or later
    1313License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    146146== Changelog ==
    147147
     148= Version 4.1.3 =
     149* Improvement of shortcodes when user sends newsletters in test mode
     150
    148151= Version 4.1.2 =
    149152* Bug fixed related to the debug mode that was not working properly
     
    511514== Upgrade Notice ==
    512515
    513 Current Version of Popup Builder is 4.1.2
     516Current Version of Popup Builder is 4.1.3
Note: See TracChangeset for help on using the changeset viewer.