Plugin Directory

Changeset 1523269


Ignore:
Timestamp:
10/27/2016 04:09:39 PM (9 years ago)
Author:
layotte
Message:

Tagging 1.36.0

Location:
ithemes-exchange
Files:
14 edited
1 copied

Legend:

Unmodified
Added
Removed
  • ithemes-exchange/tags/1.36.0/history.txt

    r1512896 r1523269  
    13111311    Fix: Compatibility with BuddyPress
    13121312    Fix: Missing break statements in Theme API.
     13131.36.0 - Lew Ayotte, Elise Alley
     1314    Update: Updating lib/classes to 2.4.8
  • ithemes-exchange/tags/1.36.0/init.php

    r1512896 r1523269  
    22/*
    33 * Plugin Name: iThemes Exchange
    4  * Version: 1.35.11
     4 * Version: 1.36.0
    55 * Text Domain: it-l10n-ithemes-exchange
    66 * Description: Easily sell your digital goods with iThemes Exchange, simple ecommerce for WordPress
     
    2525class IT_Exchange {
    2626
    27     var $_version         = '1.35.11';
     27    var $_version         = '1.36.0';
    2828    var $_wp_minimum      = '3.5';
    2929    var $_slug            = 'ithemes-exchange';
  • ithemes-exchange/tags/1.36.0/lang/ithemes-exchange.pot

    r1512896 r1523269  
    33msgid ""
    44msgstr ""
    5 "Project-Id-Version: iThemes Exchange 1.35.11\n"
     5"Project-Id-Version: iThemes Exchange 1.36.0\n"
    66"Report-Msgid-Bugs-To: http://ithemes.com/support/\n"
    7 "POT-Creation-Date: 2016-10-06 15:07:25+00:00\n"
     7"POT-Creation-Date: 2016-10-27 16:07:50+00:00\n"
    88"PO-Revision-Date: 2016-MO-DA HO:MI+ZONE\n"
    99"MIME-Version: 1.0\n"
     
    28842884msgstr ""
    28852885
    2886 #. #-#-#-#-#  ithemes-exchange.pot (iThemes Exchange 1.35.11)  #-#-#-#-#
     2886#. #-#-#-#-#  ithemes-exchange.pot (iThemes Exchange 1.36.0)  #-#-#-#-#
    28872887#. Plugin Name of the plugin/theme
    28882888#: core-addons/admin/basic-reporting/init.php:21
  • ithemes-exchange/tags/1.36.0/lib/classes/history.txt

    r1460445 r1523269  
    371371    Bug Fix: Fixed padding around dialog pop-up overlays.
    372372    Enhancement: Added support for select inputs with the multiple attribute.
     3732.4.8 - 2016-09-02 - Chris Jean
     374    Bug Fix: Fixed a typo in error message output when certain required files cannot be found.
     375    Enhancement: Removed pass-by-reference function argument on associative array check as it is no longer required. This can reduce memory usage on some servers.
  • ithemes-exchange/tags/1.36.0/lib/classes/it-utility.php

    r1288257 r1523269  
    3131if ( ! class_exists( 'ITUtility' ) ) {
    3232    it_classes_load( 'it-error.php' );
    33    
     33
    3434    class ITUtility {
    3535        public static function require_file_once( $file, $class = false ) {
     
    3838            ITUtility::check_class( $class, true );
    3939        }
    40        
     40
    4141        public static function require_file( $file, $class = false ) {
    4242            $file = ITUtility::verify_file( $file, 'require', true );
     
    4444            ITUtility::check_class( $class, true );
    4545        }
    46        
     46
    4747        public static function include_file_once( $file, $class = false ) {
    4848            $file = ITUtility::verify_file( $file, 'include_once', false );
     
    5050            ITUtility::check_class( $class, false );
    5151        }
    52        
     52
    5353        public static function include_file( $file, $class = false ) {
    5454            $file = ITUtility::verify_file( $file, 'include', false );
     
    5656            ITUtility::check_class( $class, false );
    5757        }
    58        
     58
    5959        public static function verify_file( $file, $type, $required = true ) {
    6060            if ( file_exists( get_stylesheet_directory() . "/$file" ) )
     
    6868            else if ( ! file_exists( $file ) ) {
    6969                if ( $required )
    70                     ITError::fatal( "missing_file:$type:$file", 'A file necessary for the theme to public static function is missing or unable to be read by the web server.' );
     70                    ITError::fatal( "missing_file:$type:$file", 'A file necessary for the theme to function is missing or unable to be read by the web server.' );
    7171                else {
    7272                    ITError::warn( "missing_file:$type:$file", 'A theme file is missing or unable to be read by the web server.' );
     
    7474                }
    7575            }
    76            
     76
    7777            return $file;
    7878        }
    79        
     79
    8080        public static function check_class( $class, $required = true ) {
    8181            if ( false !== $class ) {
     
    8888            }
    8989        }
    90        
     90
    9191        public static function merge_defaults( $values, $defaults, $force = false ) {
    9292            if ( ! ITUtility::is_associative_array( $defaults ) ) {
    9393                if ( ! isset( $values ) )
    9494                    return $defaults;
    95                
     95
    9696                if ( false === $force )
    9797                    return $values;
    98                
     98
    9999                if ( isset( $values ) || is_array( $values ) )
    100100                    return $values;
    101101                return $defaults;
    102102            }
    103            
     103
    104104            foreach ( (array) $defaults as $key => $val ) {
    105105                if ( ! isset( $values[$key] ) )
    106106                    $values[$key] = null;
    107                
     107
    108108                $values[$key] = ITUtility::merge_defaults( $values[$key], $val, $force );
    109109            }
    110            
     110
    111111            return $values;
    112112        }
    113        
    114         public static function is_associative_array( &$array ) {
     113
     114        public static function is_associative_array( $array ) {
    115115            if ( ! is_array( $array ) || empty( $array ) )
    116116                return false;
    117            
     117
    118118            $next = 0;
    119            
     119
    120120            foreach ( $array as $k => $v )
    121121                if ( $k !== $next++ )
    122122                    return true;
    123            
     123
    124124            return false;
    125125        }
    126        
     126
    127127        public static function show_status_message( $message ) {
    128128            echo "<div class=\"updated fade\"><p><strong>$message</strong></p></div>\n";
    129129        }
    130        
     130
    131131        public static function show_error_message( $message ) {
    132132            if ( is_wp_error( $message ) )
    133133                $message = $message->get_error_message();
    134            
     134
    135135            if ( ! is_string( $message ) )
    136136                return;
    137            
     137
    138138            echo "<div class=\"error\"><p><strong>$message</strong></p></div>\n";
    139139        }
    140        
     140
    141141        public static function show_inline_status_message( $message ) {
    142142            echo "<div class=\"updated fade inline\"><p><strong>$message</strong></p></div>\n";
    143143        }
    144        
     144
    145145        public static function show_inline_error_message( $message ) {
    146146            if ( is_wp_error( $message ) )
    147147                $message = $message->get_error_message();
    148            
     148
    149149            if ( ! is_string( $message ) )
    150150                return;
    151            
     151
    152152            echo "<div class=\"error inline\"><p><strong>$message</strong></p></div>\n";
    153153        }
    154        
     154
    155155        public static function verify_class( $var, $class ) {
    156156            if ( isset( $var ) && is_object( $var ) && ( strtolower( $class ) === strtolower( get_class( $var ) ) ) )
     
    158158            return false;
    159159        }
    160        
     160
    161161        public static function get_open_tag( $tag_name, $attributes = array() ) {
    162162            $tag = "<$tag_name";
    163            
     163
    164164            foreach ( (array) $attributes as $attribute => $values ) {
    165165                $attr_value = esc_attr( implode( ' ', (array) $values ) );
    166166                $tag .= " $attribute=\"$attr_value\"";
    167167            }
    168            
     168
    169169            $tag .= '>';
    170            
     170
    171171            return $tag;
    172172        }
    173        
     173
    174174        public static function print_open_tag( $tag_name, $attributes ) {
    175175            echo ITUtility::get_open_tag( $tag_name, $attributes ) . "\n";
    176176        }
    177        
     177
    178178        public static function get_self_closing_tag( $tag_name, $attributes = array() ) {
    179179            $tag = ITUtility::get_open_tag( $tag_name, $attributes );
    180180            $tag = preg_replace( '/>$/', ' />', $tag );
    181            
     181
    182182            return $tag;
    183183        }
    184        
     184
    185185        public static function print_self_closing_tag( $tag_name, $attributes = array() ) {
    186186            echo ITUtility::get_self_closing_tag( $tag_name, $attributes );
    187187        }
    188        
     188
    189189        public static function cleanup_request_vars() {
    190190            $_REQUEST = ITUtility::strip_slashes( $_REQUEST );
     
    192192            $_GET = ITUtility::strip_slashes( $_GET );
    193193        }
    194        
     194
    195195        public static function strip_slashes( $var ) {
    196196            if ( is_array( $var ) ) {
     
    200200            else
    201201                $var = stripslashes( $var );
    202            
     202
    203203            return $var;
    204204        }
    205        
     205
    206206        public static function sort_array( $array, $index, $args = array() ) {
    207207            it_classes_load( 'it-array-sort.php' );
    208            
     208
    209209            $sorter = new ITArraySort( $array, $index, $args );
    210            
     210
    211211            return $sorter->get_sorted_array();
    212212        }
    213        
     213
    214214        // Deprecated
    215215        public static function sort_array_by_index( $array, $index ) {
    216216            if ( ! is_array( $array ) )
    217217                ITError::fatal( 'invalid_var:parameter:array', 'Invalid data was passed to ITUtility::sort_array_by_index. This indicates a code bug.' );
    218            
     218
    219219            $new_array = array();
    220220            $indexes = array();
    221            
     221
    222222            foreach ( (array) $array as $sub_index => $sub_array )
    223223                $indexes[$sub_index] = $sub_array[$index];
    224            
     224
    225225            asort( $indexes );
    226            
     226
    227227            foreach ( (array) $indexes as $sub_index => $sub_value )
    228228                $new_array[] = $array[$sub_index];
    229            
     229
    230230            return $new_array;
    231231        }
    232        
     232
    233233        public static function get_array_value( $array, $index ) {
    234234            if ( is_string( $index ) ) {
     
    240240                }
    241241            }
    242            
     242
    243243            while ( count( $index ) > 1 ) {
    244244                if ( isset( $array[$index[0]] ) ) {
     
    249249                    return null;
    250250            }
    251            
     251
    252252            if ( isset( $array[$index[0]] ) )
    253253                return $array[$index[0]];
    254            
     254
    255255            return null;
    256256        }
    257        
     257
    258258        public static function add_array_value( &$array, $index, $val ) {
    259259            if ( is_string( $index ) ) {
     
    265265                }
    266266            }
    267            
     267
    268268            $cur_array =& $array;
    269            
     269
    270270            while ( count( $index ) > 1 ) {
    271271                if ( ! isset( $cur_array[$index[0]] ) || ! is_array( $cur_array[$index[0]] ) )
    272272                    $cur_array[$index[0]] = array();
    273                
     273
    274274                $cur_array =& $cur_array[$index[0]];
    275275                array_shift( $index );
    276276            }
    277            
     277
    278278            $cur_array[$index[0]] = $val;
    279279        }
    280        
     280
    281281        public static function print_js_vars( $options = array() ) {
    282            
     282
    283283?>
    284284    <script type="text/javascript">
     
    289289    </script>
    290290<?php
    291            
    292         }
    293        
     291
     292        }
     293
    294294        public static function print_js_script( $script ) {
    295            
     295
    296296?>
    297297    <script type="text/javascript">
     
    299299    </script>
    300300<?php
    301            
    302         }
    303        
     301
     302        }
     303
    304304        public static function add_tooltip_scripts() {
    305305            global $it_utility_cached_url_base;
    306            
     306
    307307            if ( empty( $it_utility_cached_url_base ) )
    308308                $it_utility_cached_url_base = ITUtility::get_url_from_file( dirname( __FILE__ ) );
    309            
     309
    310310            wp_enqueue_script( 'jquery-tooltip', $it_utility_cached_url_base . '/js/jquery.tooltip.js', array( 'jquery' ) );
    311311            wp_enqueue_script( 'it-tooltip', $it_utility_cached_url_base . '/js/it-tooltip.js', array( 'jquery-tooltip' ) );
    312312        }
    313        
     313
    314314        public static function add_tooltip_styles() {
    315315            global $it_utility_cached_url_base;
    316            
     316
    317317            if ( empty( $it_utility_cached_url_base ) )
    318318                $it_utility_cached_url_base = ITUtility::get_url_from_file( dirname( __FILE__ ) );
    319            
     319
    320320            wp_enqueue_style( 'it-tooltip', $it_utility_cached_url_base . '/css/it-tooltip.css' );
    321321        }
    322        
     322
    323323        public static function get_tooltip( $message, $title = '', $class = '', $alt = '(?)' ) {
    324324            global $it_utility_cached_url_base;
    325            
     325
    326326            if ( empty( $it_utility_cached_url_base ) )
    327327                $it_utility_cached_url_base = ITUtility::get_url_from_file( dirname( __FILE__ ) );
    328            
     328
    329329            $message = esc_attr( $message );
    330330            $title = esc_attr( $title );
    331            
     331
    332332            if ( empty( $class ) )
    333333                $class = 'it-tooltip';
    334334            else
    335335                $class = "it-tooltip-$class";
    336            
     336
    337337            $tip = "<a class='$class' title='$title |:|~| $message'><img src='" . $it_utility_cached_url_base . "/images/it-tooltip.png' alt='(?)' /></a>";
    338            
     338
    339339            return $tip;
    340340        }
    341        
     341
    342342        public static function add_tooltip( $message, $title = '', $class = '', $alt = '(?)' ) {
    343343            echo ITUtility::get_tooltip( $message, $title, $class, $alt );
    344344        }
    345        
     345
    346346        /* Changes http protocols to https when is_ssl() is true and https protocols to http otherwise */
    347347        public static function fix_url( $url ) {
     
    351351                $url = preg_replace( '|^https://|', 'http://', $url );
    352352            }
    353            
     353
    354354            return $url;
    355355        }
    356        
     356
    357357        public static function get_random_string( $length = 10, $use_sets = array( 'lower', 'upper', 'num' ) ) {
    358358            $sets = array(
     
    363363                'extended' => '`~!@#$%^&*()=+[]{};:\'"<>/?\|',
    364364            );
    365            
    366            
     365
     366
    367367            if ( is_array( $length ) ) {
    368368                if ( ! isset( $length[0] ) || ! isset( $length[1] ) )
    369369                    return '';
    370                
     370
    371371                $lower = intval( $length[0] );
    372372                $upper = intval( $length[1] );
    373                
     373
    374374                $length = rand( $lower, $upper );
    375375            }
    376376            else
    377377                $length = intval( $length );
    378            
     378
    379379            if ( $length < 1 )
    380380                $length = 1;
    381            
    382            
     381
     382
    383383            $source_string = '';
    384            
     384
    385385            if ( is_string( $use_sets ) )
    386386                $source_string = $use_sets;
     
    395395                    $source_string .= $chars;
    396396            }
    397            
     397
    398398            if ( empty( $source_string ) )
    399399                return false;
    400            
    401            
     400
     401
    402402            $string = '';
    403            
     403
    404404            while ( strlen( $string ) < $length )
    405405                $string .= substr( $source_string, rand( 0, strlen( $source_string ) - 1 ), 1 );
    406            
    407            
     406
     407
    408408            return $string;
    409409        }
    410        
     410
    411411        public static function pad( $depth, $pad = '    ' ) {
    412412            $retval = '';
    413            
     413
    414414            for ( $x = 0; $x <= $depth; $x++ )
    415415                $retval .= $pad;
    416            
     416
    417417            return $retval;
    418418        }
    419        
     419
    420420        public static function get_url_from_file( $file, $auto_ssl = true, $prevent_recursion = false ) {
    421421            $file = str_replace( '\\', '/', $file );
    422            
     422
    423423            $url = '';
    424            
     424
    425425            $upload_dir = ITUtility::get_cached_value( 'wp_upload_dir' );
    426426            $upload_dir['basedir'] = str_replace( '\\', '/', $upload_dir['basedir'] );
    427            
     427
    428428            if ( is_array( $upload_dir ) && ( false === $upload_dir['error'] ) ) {
    429429                if ( 0 === strpos( $file, $upload_dir['basedir'] ) ) {
     
    432432                    $path_pattern = 'wp-content/uploads';
    433433                    $url_base = $upload_dir['baseurl'];
    434                    
     434
    435435                    if ( is_multisite() && ! ( is_main_network() && is_main_site() && defined( 'MULTISITE' ) ) ) {
    436436                        if ( defined( 'MULTISITE' ) ) {
     
    439439                            $mu_path = '/' . get_current_blog_id();
    440440                        }
    441                        
     441
    442442                        if ( false === strpos( $file, "$path_pattern$mu_path" ) ) {
    443443                            $url_base = substr( $url_base, 0, - strlen( $mu_path ) );
     
    446446                        }
    447447                    }
    448                    
     448
    449449                    $url = $url_base . substr( $file, strpos( $file, $path_pattern ) + strlen( $path_pattern ) );
    450450                }
    451451            }
    452            
     452
    453453            if ( empty( $url ) ) {
    454454                if ( ! isset( $GLOBALS['it_classes_cache_wp_content_dir'] ) )
     
    456456                if ( ! isset( $GLOBALS['it_classes_cache_abspath'] ) )
    457457                    $GLOBALS['it_classes_cache_abspath'] = rtrim( str_replace( '\\', '/', ABSPATH ), '/' );
    458                
     458
    459459                if ( 0 === strpos( $file, $GLOBALS['it_classes_cache_wp_content_dir'] ) )
    460460                    $url = WP_CONTENT_URL . str_replace( '\\', '/', preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_wp_content_dir'], '/' ) . '/', '', $file ) );
     
    462462                    $url = get_option( 'siteurl' ) . str_replace( '\\', '/', preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_abspath'], '/' ) . '/', '', $file ) );
    463463            }
    464            
     464
    465465            if ( empty( $url ) && ! $prevent_recursion )
    466466                $url = ITUtility::get_url_from_file( realpath( $file ), $auto_ssl, true );
    467            
     467
    468468            if ( empty( $url ) )
    469469                return '';
    470            
    471            
     470
     471
    472472            if ( $auto_ssl )
    473473                $url = ITUtility::fix_url( $url );
    474            
     474
    475475            return $url;
    476476        }
    477        
     477
    478478        public static function get_file_from_url( $url ) {
    479479            $url = preg_replace( '/^https/', 'http', $url );
    480480            $url = preg_replace( '/\?.*$/', '', $url );
    481            
     481
    482482            $file = '';
    483            
     483
    484484            $upload_dir = ITUtility::get_cached_value( 'wp_upload_dir' );
    485            
     485
    486486            if ( is_array( $upload_dir ) && ( false === $upload_dir['error'] ) ) {
    487487                if ( 0 === strpos( $url, $upload_dir['baseurl'] ) ) {
     
    490490                    $path_pattern = 'wp-content/uploads';
    491491                    $file_base = $upload_dir['basedir'];
    492                    
     492
    493493                    if ( is_multisite() && ! ( is_main_network() && is_main_site() && defined( 'MULTISITE' ) ) ) {
    494494                        if ( defined( 'MULTISITE' ) ) {
     
    497497                            $mu_path = '/' . get_current_blog_id();
    498498                        }
    499                        
     499
    500500                        if ( false === strpos( $url, "$path_pattern$mu_path" ) ) {
    501501                            $file_base = substr( $file_base, 0, - strlen( $mu_path ) );
     
    504504                        }
    505505                    }
    506                    
     506
    507507                    $file = $file_base . substr( $url, strpos( $url, $path_pattern ) + strlen( $path_pattern ) );
    508508                }
    509509            }
    510            
     510
    511511            if ( empty( $file ) ) {
    512512                if ( ! isset( $GLOBALS['it_classes_cache_wp_content_url'] ) )
     
    514514                if ( ! isset( $GLOBALS['it_classes_cache_siteurl'] ) )
    515515                    $GLOBALS['it_classes_cache_siteurl'] = preg_replace( '/^https/', 'http', get_option( 'siteurl' ) );
    516                
     516
    517517                if ( 0 === strpos( $url, $GLOBALS['it_classes_cache_wp_content_url'] ) )
    518518                    $file = rtrim( WP_CONTENT_DIR, '\\\/' ) . preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_wp_content_url'], '/' ) . '/', '', $url );
     
    522522                    $file = rtrim( ABSPATH, '\\\/' ) . preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_siteurl'], '/' ) . '/', '', $url );
    523523            }
    524            
     524
    525525            return $file;
    526526        }
    527        
     527
    528528        public static function get_cached_value( $function, $args = array() ) {
    529529            if ( ! isset( $GLOBALS['it_classes_cached_values'] ) )
    530530                $GLOBALS['it_classes_cached_values'] = array();
    531            
     531
    532532            $key = $function;
    533            
     533
    534534            if ( ! empty( $args ) )
    535535                $key .= '-' . md5( serialize( $args ) );
    536            
     536
    537537            if ( ! isset( $GLOBALS['it_classes_cached_values'][$key] ) )
    538538                $GLOBALS['it_classes_cached_values'][$key] = call_user_func_array( $function, $args );
    539            
     539
    540540            return $GLOBALS['it_classes_cached_values'][$key];
    541541        }
    542        
     542
    543543        // WordPress 3.8 deprecates the screen_icon function. Replacing all instances of screen_icon with ITUtility::screen_icon allows for easy backcompat while avoiding the deprecation notices.
    544544        public static function screen_icon() {
     
    547547            }
    548548        }
    549        
    550        
     549
     550
    551551        /* Debug Functions */
    552552        /* These functions are no part of the ITDebug class. These are retained for legacy purposes. */
    553        
     553
    554554        public static function print_r( $data, $description = '', $expand_objects = true, $max_depth = -1 ) {
    555555            it_classes_load( 'it-debug.php' );
    556            
     556
    557557            $args = compact( 'description', 'expand_objects', 'max_depth' );
    558            
     558
    559559            ITDebug::print_r( $data, $args );
    560560        }
    561        
     561
    562562        public static function backtrace( $description = false, $expand_objects = false, $max_depth = 3 ) {
    563563            it_classes_load( 'it-debug.php' );
    564            
     564
    565565            $args = compact( 'description', 'expand_objects', 'max_depth' );
    566566            $args['offset'] = 1;
    567            
     567
    568568            ITDebug::backtrace( $args );
    569569        }
    570        
     570
    571571        public static function inspect( $data, $expand_objects = false, $max_depth = 2, $echo = true ) {
    572572            it_classes_load( 'it-debug.php' );
    573            
     573
    574574            $args = compact( 'expand_objects', 'max_depth', 'echo' );
    575            
     575
    576576            return ITDebug::inspect( $data, $args );
    577577        }
    578        
     578
    579579        public static function is_callable_function( $function ) {
    580580            if ( ! is_callable( $function ) ) {
    581581                return false;
    582582            }
    583            
     583
    584584            if ( ! isset( $GLOBALS['it_classes_cached_values'] ) ) {
    585585                $GLOBALS['it_classes_cached_values'] = array();
    586586            }
    587            
     587
    588588            if ( ! isset( $GLOBALS['it_classes_cached_values']['ini_get:disable_functions'] ) ) {
    589589                $GLOBALS['it_classes_cached_values']['var:disable_functions'] = preg_split( '/\s*,\s*/', (string) ini_get( 'disable_functions' ) );
    590590            }
    591            
     591
    592592            if ( in_array( $function, $GLOBALS['it_classes_cached_values']['var:disable_functions'] ) ) {
    593593                return false;
    594594            }
    595            
     595
    596596            if ( ! isset( $GLOBALS['it_classes_cached_values']['ini_get:suhosin.executor.func.blacklist'] ) ) {
    597597                $GLOBALS['it_classes_cached_values']['ini_get:suhosin.executor.func.blacklist'] = preg_split( '/\s*,\s*/', (string) ini_get( 'suhosin.executor.func.blacklist' ) );
    598598            }
    599            
     599
    600600            if ( in_array( $function, $GLOBALS['it_classes_cached_values']['ini_get:suhosin.executor.func.blacklist'] ) ) {
    601601                return false;
    602602            }
    603            
     603
    604604            return true;
    605605        }
  • ithemes-exchange/tags/1.36.0/lib/classes/load.php

    r1326981 r1523269  
    33/*
    44Written by Chris Jean for iThemes.com
    5 Version 2.4.7
     5Version 2.4.8
    66*/
    77
    88
    9 $it_registration_list_version   = '2.4.7';
     9$it_registration_list_version   = '2.4.8';
    1010$it_registration_list_library   = 'classes';
    1111$it_registration_list_init_file = dirname( __FILE__ ) . '/init.php';
     
    2020        if ( ! isset( $wp_locale ) )
    2121            return;
    22        
    23        
     22
     23
    2424        $init_files = array();
    25        
     25
    2626        foreach ( (array) $GLOBALS['it_classes_registration_list'] as $library => $versions ) {
    2727            $max_version = '-10000';
    2828            $init_file = '';
    29            
     29
    3030            foreach ( (array) $versions as $version => $file ) {
    3131                if ( version_compare( $version, $max_version, '>' ) ) {
     
    3434                }
    3535            }
    36            
     36
    3737            if ( ! empty( $init_file ) )
    3838                $init_files[] = $init_file;
    3939        }
    40        
     40
    4141        unset( $GLOBALS['it_classes_registration_list'] );
    42        
     42
    4343        foreach ( (array) $init_files as $init_file )
    4444            require_once( $init_file );
    45        
     45
    4646        do_action( 'it_libraries_loaded' );
    4747    }
    48    
     48
    4949    global $wp_version;
    50    
     50
    5151    if ( version_compare( $wp_version, '2.9.7', '>' ) )
    5252        add_action( 'after_setup_theme', 'it_registration_list_init' );
  • ithemes-exchange/tags/1.36.0/readme.txt

    r1512896 r1523269  
    33Tags: ecommerce
    44Requires at least: 3.7
    5 Tested up to: 4.6
    6 Stable tag: 1.35.11
     5Tested up to: 4.7
     6Stable tag: 1.36.0
    77License: GPLv2 or later
    88
     
    8888
    8989== Changelog ==
     90
     91= 1.36.0 =
     92* Update: Updating lib/classes to v2.4.8
    9093
    9194= 1.35.11 =
  • ithemes-exchange/trunk/history.txt

    r1512896 r1523269  
    13111311    Fix: Compatibility with BuddyPress
    13121312    Fix: Missing break statements in Theme API.
     13131.36.0 - Lew Ayotte, Elise Alley
     1314    Update: Updating lib/classes to 2.4.8
  • ithemes-exchange/trunk/init.php

    r1512896 r1523269  
    22/*
    33 * Plugin Name: iThemes Exchange
    4  * Version: 1.35.11
     4 * Version: 1.36.0
    55 * Text Domain: it-l10n-ithemes-exchange
    66 * Description: Easily sell your digital goods with iThemes Exchange, simple ecommerce for WordPress
     
    2525class IT_Exchange {
    2626
    27     var $_version         = '1.35.11';
     27    var $_version         = '1.36.0';
    2828    var $_wp_minimum      = '3.5';
    2929    var $_slug            = 'ithemes-exchange';
  • ithemes-exchange/trunk/lang/ithemes-exchange.pot

    r1512896 r1523269  
    33msgid ""
    44msgstr ""
    5 "Project-Id-Version: iThemes Exchange 1.35.11\n"
     5"Project-Id-Version: iThemes Exchange 1.36.0\n"
    66"Report-Msgid-Bugs-To: http://ithemes.com/support/\n"
    7 "POT-Creation-Date: 2016-10-06 15:07:25+00:00\n"
     7"POT-Creation-Date: 2016-10-27 16:07:50+00:00\n"
    88"PO-Revision-Date: 2016-MO-DA HO:MI+ZONE\n"
    99"MIME-Version: 1.0\n"
     
    28842884msgstr ""
    28852885
    2886 #. #-#-#-#-#  ithemes-exchange.pot (iThemes Exchange 1.35.11)  #-#-#-#-#
     2886#. #-#-#-#-#  ithemes-exchange.pot (iThemes Exchange 1.36.0)  #-#-#-#-#
    28872887#. Plugin Name of the plugin/theme
    28882888#: core-addons/admin/basic-reporting/init.php:21
  • ithemes-exchange/trunk/lib/classes/history.txt

    r1460445 r1523269  
    371371    Bug Fix: Fixed padding around dialog pop-up overlays.
    372372    Enhancement: Added support for select inputs with the multiple attribute.
     3732.4.8 - 2016-09-02 - Chris Jean
     374    Bug Fix: Fixed a typo in error message output when certain required files cannot be found.
     375    Enhancement: Removed pass-by-reference function argument on associative array check as it is no longer required. This can reduce memory usage on some servers.
  • ithemes-exchange/trunk/lib/classes/it-utility.php

    r1288257 r1523269  
    3131if ( ! class_exists( 'ITUtility' ) ) {
    3232    it_classes_load( 'it-error.php' );
    33    
     33
    3434    class ITUtility {
    3535        public static function require_file_once( $file, $class = false ) {
     
    3838            ITUtility::check_class( $class, true );
    3939        }
    40        
     40
    4141        public static function require_file( $file, $class = false ) {
    4242            $file = ITUtility::verify_file( $file, 'require', true );
     
    4444            ITUtility::check_class( $class, true );
    4545        }
    46        
     46
    4747        public static function include_file_once( $file, $class = false ) {
    4848            $file = ITUtility::verify_file( $file, 'include_once', false );
     
    5050            ITUtility::check_class( $class, false );
    5151        }
    52        
     52
    5353        public static function include_file( $file, $class = false ) {
    5454            $file = ITUtility::verify_file( $file, 'include', false );
     
    5656            ITUtility::check_class( $class, false );
    5757        }
    58        
     58
    5959        public static function verify_file( $file, $type, $required = true ) {
    6060            if ( file_exists( get_stylesheet_directory() . "/$file" ) )
     
    6868            else if ( ! file_exists( $file ) ) {
    6969                if ( $required )
    70                     ITError::fatal( "missing_file:$type:$file", 'A file necessary for the theme to public static function is missing or unable to be read by the web server.' );
     70                    ITError::fatal( "missing_file:$type:$file", 'A file necessary for the theme to function is missing or unable to be read by the web server.' );
    7171                else {
    7272                    ITError::warn( "missing_file:$type:$file", 'A theme file is missing or unable to be read by the web server.' );
     
    7474                }
    7575            }
    76            
     76
    7777            return $file;
    7878        }
    79        
     79
    8080        public static function check_class( $class, $required = true ) {
    8181            if ( false !== $class ) {
     
    8888            }
    8989        }
    90        
     90
    9191        public static function merge_defaults( $values, $defaults, $force = false ) {
    9292            if ( ! ITUtility::is_associative_array( $defaults ) ) {
    9393                if ( ! isset( $values ) )
    9494                    return $defaults;
    95                
     95
    9696                if ( false === $force )
    9797                    return $values;
    98                
     98
    9999                if ( isset( $values ) || is_array( $values ) )
    100100                    return $values;
    101101                return $defaults;
    102102            }
    103            
     103
    104104            foreach ( (array) $defaults as $key => $val ) {
    105105                if ( ! isset( $values[$key] ) )
    106106                    $values[$key] = null;
    107                
     107
    108108                $values[$key] = ITUtility::merge_defaults( $values[$key], $val, $force );
    109109            }
    110            
     110
    111111            return $values;
    112112        }
    113        
    114         public static function is_associative_array( &$array ) {
     113
     114        public static function is_associative_array( $array ) {
    115115            if ( ! is_array( $array ) || empty( $array ) )
    116116                return false;
    117            
     117
    118118            $next = 0;
    119            
     119
    120120            foreach ( $array as $k => $v )
    121121                if ( $k !== $next++ )
    122122                    return true;
    123            
     123
    124124            return false;
    125125        }
    126        
     126
    127127        public static function show_status_message( $message ) {
    128128            echo "<div class=\"updated fade\"><p><strong>$message</strong></p></div>\n";
    129129        }
    130        
     130
    131131        public static function show_error_message( $message ) {
    132132            if ( is_wp_error( $message ) )
    133133                $message = $message->get_error_message();
    134            
     134
    135135            if ( ! is_string( $message ) )
    136136                return;
    137            
     137
    138138            echo "<div class=\"error\"><p><strong>$message</strong></p></div>\n";
    139139        }
    140        
     140
    141141        public static function show_inline_status_message( $message ) {
    142142            echo "<div class=\"updated fade inline\"><p><strong>$message</strong></p></div>\n";
    143143        }
    144        
     144
    145145        public static function show_inline_error_message( $message ) {
    146146            if ( is_wp_error( $message ) )
    147147                $message = $message->get_error_message();
    148            
     148
    149149            if ( ! is_string( $message ) )
    150150                return;
    151            
     151
    152152            echo "<div class=\"error inline\"><p><strong>$message</strong></p></div>\n";
    153153        }
    154        
     154
    155155        public static function verify_class( $var, $class ) {
    156156            if ( isset( $var ) && is_object( $var ) && ( strtolower( $class ) === strtolower( get_class( $var ) ) ) )
     
    158158            return false;
    159159        }
    160        
     160
    161161        public static function get_open_tag( $tag_name, $attributes = array() ) {
    162162            $tag = "<$tag_name";
    163            
     163
    164164            foreach ( (array) $attributes as $attribute => $values ) {
    165165                $attr_value = esc_attr( implode( ' ', (array) $values ) );
    166166                $tag .= " $attribute=\"$attr_value\"";
    167167            }
    168            
     168
    169169            $tag .= '>';
    170            
     170
    171171            return $tag;
    172172        }
    173        
     173
    174174        public static function print_open_tag( $tag_name, $attributes ) {
    175175            echo ITUtility::get_open_tag( $tag_name, $attributes ) . "\n";
    176176        }
    177        
     177
    178178        public static function get_self_closing_tag( $tag_name, $attributes = array() ) {
    179179            $tag = ITUtility::get_open_tag( $tag_name, $attributes );
    180180            $tag = preg_replace( '/>$/', ' />', $tag );
    181            
     181
    182182            return $tag;
    183183        }
    184        
     184
    185185        public static function print_self_closing_tag( $tag_name, $attributes = array() ) {
    186186            echo ITUtility::get_self_closing_tag( $tag_name, $attributes );
    187187        }
    188        
     188
    189189        public static function cleanup_request_vars() {
    190190            $_REQUEST = ITUtility::strip_slashes( $_REQUEST );
     
    192192            $_GET = ITUtility::strip_slashes( $_GET );
    193193        }
    194        
     194
    195195        public static function strip_slashes( $var ) {
    196196            if ( is_array( $var ) ) {
     
    200200            else
    201201                $var = stripslashes( $var );
    202            
     202
    203203            return $var;
    204204        }
    205        
     205
    206206        public static function sort_array( $array, $index, $args = array() ) {
    207207            it_classes_load( 'it-array-sort.php' );
    208            
     208
    209209            $sorter = new ITArraySort( $array, $index, $args );
    210            
     210
    211211            return $sorter->get_sorted_array();
    212212        }
    213        
     213
    214214        // Deprecated
    215215        public static function sort_array_by_index( $array, $index ) {
    216216            if ( ! is_array( $array ) )
    217217                ITError::fatal( 'invalid_var:parameter:array', 'Invalid data was passed to ITUtility::sort_array_by_index. This indicates a code bug.' );
    218            
     218
    219219            $new_array = array();
    220220            $indexes = array();
    221            
     221
    222222            foreach ( (array) $array as $sub_index => $sub_array )
    223223                $indexes[$sub_index] = $sub_array[$index];
    224            
     224
    225225            asort( $indexes );
    226            
     226
    227227            foreach ( (array) $indexes as $sub_index => $sub_value )
    228228                $new_array[] = $array[$sub_index];
    229            
     229
    230230            return $new_array;
    231231        }
    232        
     232
    233233        public static function get_array_value( $array, $index ) {
    234234            if ( is_string( $index ) ) {
     
    240240                }
    241241            }
    242            
     242
    243243            while ( count( $index ) > 1 ) {
    244244                if ( isset( $array[$index[0]] ) ) {
     
    249249                    return null;
    250250            }
    251            
     251
    252252            if ( isset( $array[$index[0]] ) )
    253253                return $array[$index[0]];
    254            
     254
    255255            return null;
    256256        }
    257        
     257
    258258        public static function add_array_value( &$array, $index, $val ) {
    259259            if ( is_string( $index ) ) {
     
    265265                }
    266266            }
    267            
     267
    268268            $cur_array =& $array;
    269            
     269
    270270            while ( count( $index ) > 1 ) {
    271271                if ( ! isset( $cur_array[$index[0]] ) || ! is_array( $cur_array[$index[0]] ) )
    272272                    $cur_array[$index[0]] = array();
    273                
     273
    274274                $cur_array =& $cur_array[$index[0]];
    275275                array_shift( $index );
    276276            }
    277            
     277
    278278            $cur_array[$index[0]] = $val;
    279279        }
    280        
     280
    281281        public static function print_js_vars( $options = array() ) {
    282            
     282
    283283?>
    284284    <script type="text/javascript">
     
    289289    </script>
    290290<?php
    291            
    292         }
    293        
     291
     292        }
     293
    294294        public static function print_js_script( $script ) {
    295            
     295
    296296?>
    297297    <script type="text/javascript">
     
    299299    </script>
    300300<?php
    301            
    302         }
    303        
     301
     302        }
     303
    304304        public static function add_tooltip_scripts() {
    305305            global $it_utility_cached_url_base;
    306            
     306
    307307            if ( empty( $it_utility_cached_url_base ) )
    308308                $it_utility_cached_url_base = ITUtility::get_url_from_file( dirname( __FILE__ ) );
    309            
     309
    310310            wp_enqueue_script( 'jquery-tooltip', $it_utility_cached_url_base . '/js/jquery.tooltip.js', array( 'jquery' ) );
    311311            wp_enqueue_script( 'it-tooltip', $it_utility_cached_url_base . '/js/it-tooltip.js', array( 'jquery-tooltip' ) );
    312312        }
    313        
     313
    314314        public static function add_tooltip_styles() {
    315315            global $it_utility_cached_url_base;
    316            
     316
    317317            if ( empty( $it_utility_cached_url_base ) )
    318318                $it_utility_cached_url_base = ITUtility::get_url_from_file( dirname( __FILE__ ) );
    319            
     319
    320320            wp_enqueue_style( 'it-tooltip', $it_utility_cached_url_base . '/css/it-tooltip.css' );
    321321        }
    322        
     322
    323323        public static function get_tooltip( $message, $title = '', $class = '', $alt = '(?)' ) {
    324324            global $it_utility_cached_url_base;
    325            
     325
    326326            if ( empty( $it_utility_cached_url_base ) )
    327327                $it_utility_cached_url_base = ITUtility::get_url_from_file( dirname( __FILE__ ) );
    328            
     328
    329329            $message = esc_attr( $message );
    330330            $title = esc_attr( $title );
    331            
     331
    332332            if ( empty( $class ) )
    333333                $class = 'it-tooltip';
    334334            else
    335335                $class = "it-tooltip-$class";
    336            
     336
    337337            $tip = "<a class='$class' title='$title |:|~| $message'><img src='" . $it_utility_cached_url_base . "/images/it-tooltip.png' alt='(?)' /></a>";
    338            
     338
    339339            return $tip;
    340340        }
    341        
     341
    342342        public static function add_tooltip( $message, $title = '', $class = '', $alt = '(?)' ) {
    343343            echo ITUtility::get_tooltip( $message, $title, $class, $alt );
    344344        }
    345        
     345
    346346        /* Changes http protocols to https when is_ssl() is true and https protocols to http otherwise */
    347347        public static function fix_url( $url ) {
     
    351351                $url = preg_replace( '|^https://|', 'http://', $url );
    352352            }
    353            
     353
    354354            return $url;
    355355        }
    356        
     356
    357357        public static function get_random_string( $length = 10, $use_sets = array( 'lower', 'upper', 'num' ) ) {
    358358            $sets = array(
     
    363363                'extended' => '`~!@#$%^&*()=+[]{};:\'"<>/?\|',
    364364            );
    365            
    366            
     365
     366
    367367            if ( is_array( $length ) ) {
    368368                if ( ! isset( $length[0] ) || ! isset( $length[1] ) )
    369369                    return '';
    370                
     370
    371371                $lower = intval( $length[0] );
    372372                $upper = intval( $length[1] );
    373                
     373
    374374                $length = rand( $lower, $upper );
    375375            }
    376376            else
    377377                $length = intval( $length );
    378            
     378
    379379            if ( $length < 1 )
    380380                $length = 1;
    381            
    382            
     381
     382
    383383            $source_string = '';
    384            
     384
    385385            if ( is_string( $use_sets ) )
    386386                $source_string = $use_sets;
     
    395395                    $source_string .= $chars;
    396396            }
    397            
     397
    398398            if ( empty( $source_string ) )
    399399                return false;
    400            
    401            
     400
     401
    402402            $string = '';
    403            
     403
    404404            while ( strlen( $string ) < $length )
    405405                $string .= substr( $source_string, rand( 0, strlen( $source_string ) - 1 ), 1 );
    406            
    407            
     406
     407
    408408            return $string;
    409409        }
    410        
     410
    411411        public static function pad( $depth, $pad = '    ' ) {
    412412            $retval = '';
    413            
     413
    414414            for ( $x = 0; $x <= $depth; $x++ )
    415415                $retval .= $pad;
    416            
     416
    417417            return $retval;
    418418        }
    419        
     419
    420420        public static function get_url_from_file( $file, $auto_ssl = true, $prevent_recursion = false ) {
    421421            $file = str_replace( '\\', '/', $file );
    422            
     422
    423423            $url = '';
    424            
     424
    425425            $upload_dir = ITUtility::get_cached_value( 'wp_upload_dir' );
    426426            $upload_dir['basedir'] = str_replace( '\\', '/', $upload_dir['basedir'] );
    427            
     427
    428428            if ( is_array( $upload_dir ) && ( false === $upload_dir['error'] ) ) {
    429429                if ( 0 === strpos( $file, $upload_dir['basedir'] ) ) {
     
    432432                    $path_pattern = 'wp-content/uploads';
    433433                    $url_base = $upload_dir['baseurl'];
    434                    
     434
    435435                    if ( is_multisite() && ! ( is_main_network() && is_main_site() && defined( 'MULTISITE' ) ) ) {
    436436                        if ( defined( 'MULTISITE' ) ) {
     
    439439                            $mu_path = '/' . get_current_blog_id();
    440440                        }
    441                        
     441
    442442                        if ( false === strpos( $file, "$path_pattern$mu_path" ) ) {
    443443                            $url_base = substr( $url_base, 0, - strlen( $mu_path ) );
     
    446446                        }
    447447                    }
    448                    
     448
    449449                    $url = $url_base . substr( $file, strpos( $file, $path_pattern ) + strlen( $path_pattern ) );
    450450                }
    451451            }
    452            
     452
    453453            if ( empty( $url ) ) {
    454454                if ( ! isset( $GLOBALS['it_classes_cache_wp_content_dir'] ) )
     
    456456                if ( ! isset( $GLOBALS['it_classes_cache_abspath'] ) )
    457457                    $GLOBALS['it_classes_cache_abspath'] = rtrim( str_replace( '\\', '/', ABSPATH ), '/' );
    458                
     458
    459459                if ( 0 === strpos( $file, $GLOBALS['it_classes_cache_wp_content_dir'] ) )
    460460                    $url = WP_CONTENT_URL . str_replace( '\\', '/', preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_wp_content_dir'], '/' ) . '/', '', $file ) );
     
    462462                    $url = get_option( 'siteurl' ) . str_replace( '\\', '/', preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_abspath'], '/' ) . '/', '', $file ) );
    463463            }
    464            
     464
    465465            if ( empty( $url ) && ! $prevent_recursion )
    466466                $url = ITUtility::get_url_from_file( realpath( $file ), $auto_ssl, true );
    467            
     467
    468468            if ( empty( $url ) )
    469469                return '';
    470            
    471            
     470
     471
    472472            if ( $auto_ssl )
    473473                $url = ITUtility::fix_url( $url );
    474            
     474
    475475            return $url;
    476476        }
    477        
     477
    478478        public static function get_file_from_url( $url ) {
    479479            $url = preg_replace( '/^https/', 'http', $url );
    480480            $url = preg_replace( '/\?.*$/', '', $url );
    481            
     481
    482482            $file = '';
    483            
     483
    484484            $upload_dir = ITUtility::get_cached_value( 'wp_upload_dir' );
    485            
     485
    486486            if ( is_array( $upload_dir ) && ( false === $upload_dir['error'] ) ) {
    487487                if ( 0 === strpos( $url, $upload_dir['baseurl'] ) ) {
     
    490490                    $path_pattern = 'wp-content/uploads';
    491491                    $file_base = $upload_dir['basedir'];
    492                    
     492
    493493                    if ( is_multisite() && ! ( is_main_network() && is_main_site() && defined( 'MULTISITE' ) ) ) {
    494494                        if ( defined( 'MULTISITE' ) ) {
     
    497497                            $mu_path = '/' . get_current_blog_id();
    498498                        }
    499                        
     499
    500500                        if ( false === strpos( $url, "$path_pattern$mu_path" ) ) {
    501501                            $file_base = substr( $file_base, 0, - strlen( $mu_path ) );
     
    504504                        }
    505505                    }
    506                    
     506
    507507                    $file = $file_base . substr( $url, strpos( $url, $path_pattern ) + strlen( $path_pattern ) );
    508508                }
    509509            }
    510            
     510
    511511            if ( empty( $file ) ) {
    512512                if ( ! isset( $GLOBALS['it_classes_cache_wp_content_url'] ) )
     
    514514                if ( ! isset( $GLOBALS['it_classes_cache_siteurl'] ) )
    515515                    $GLOBALS['it_classes_cache_siteurl'] = preg_replace( '/^https/', 'http', get_option( 'siteurl' ) );
    516                
     516
    517517                if ( 0 === strpos( $url, $GLOBALS['it_classes_cache_wp_content_url'] ) )
    518518                    $file = rtrim( WP_CONTENT_DIR, '\\\/' ) . preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_wp_content_url'], '/' ) . '/', '', $url );
     
    522522                    $file = rtrim( ABSPATH, '\\\/' ) . preg_replace( '/^' . preg_quote( $GLOBALS['it_classes_cache_siteurl'], '/' ) . '/', '', $url );
    523523            }
    524            
     524
    525525            return $file;
    526526        }
    527        
     527
    528528        public static function get_cached_value( $function, $args = array() ) {
    529529            if ( ! isset( $GLOBALS['it_classes_cached_values'] ) )
    530530                $GLOBALS['it_classes_cached_values'] = array();
    531            
     531
    532532            $key = $function;
    533            
     533
    534534            if ( ! empty( $args ) )
    535535                $key .= '-' . md5( serialize( $args ) );
    536            
     536
    537537            if ( ! isset( $GLOBALS['it_classes_cached_values'][$key] ) )
    538538                $GLOBALS['it_classes_cached_values'][$key] = call_user_func_array( $function, $args );
    539            
     539
    540540            return $GLOBALS['it_classes_cached_values'][$key];
    541541        }
    542        
     542
    543543        // WordPress 3.8 deprecates the screen_icon function. Replacing all instances of screen_icon with ITUtility::screen_icon allows for easy backcompat while avoiding the deprecation notices.
    544544        public static function screen_icon() {
     
    547547            }
    548548        }
    549        
    550        
     549
     550
    551551        /* Debug Functions */
    552552        /* These functions are no part of the ITDebug class. These are retained for legacy purposes. */
    553        
     553
    554554        public static function print_r( $data, $description = '', $expand_objects = true, $max_depth = -1 ) {
    555555            it_classes_load( 'it-debug.php' );
    556            
     556
    557557            $args = compact( 'description', 'expand_objects', 'max_depth' );
    558            
     558
    559559            ITDebug::print_r( $data, $args );
    560560        }
    561        
     561
    562562        public static function backtrace( $description = false, $expand_objects = false, $max_depth = 3 ) {
    563563            it_classes_load( 'it-debug.php' );
    564            
     564
    565565            $args = compact( 'description', 'expand_objects', 'max_depth' );
    566566            $args['offset'] = 1;
    567            
     567
    568568            ITDebug::backtrace( $args );
    569569        }
    570        
     570
    571571        public static function inspect( $data, $expand_objects = false, $max_depth = 2, $echo = true ) {
    572572            it_classes_load( 'it-debug.php' );
    573            
     573
    574574            $args = compact( 'expand_objects', 'max_depth', 'echo' );
    575            
     575
    576576            return ITDebug::inspect( $data, $args );
    577577        }
    578        
     578
    579579        public static function is_callable_function( $function ) {
    580580            if ( ! is_callable( $function ) ) {
    581581                return false;
    582582            }
    583            
     583
    584584            if ( ! isset( $GLOBALS['it_classes_cached_values'] ) ) {
    585585                $GLOBALS['it_classes_cached_values'] = array();
    586586            }
    587            
     587
    588588            if ( ! isset( $GLOBALS['it_classes_cached_values']['ini_get:disable_functions'] ) ) {
    589589                $GLOBALS['it_classes_cached_values']['var:disable_functions'] = preg_split( '/\s*,\s*/', (string) ini_get( 'disable_functions' ) );
    590590            }
    591            
     591
    592592            if ( in_array( $function, $GLOBALS['it_classes_cached_values']['var:disable_functions'] ) ) {
    593593                return false;
    594594            }
    595            
     595
    596596            if ( ! isset( $GLOBALS['it_classes_cached_values']['ini_get:suhosin.executor.func.blacklist'] ) ) {
    597597                $GLOBALS['it_classes_cached_values']['ini_get:suhosin.executor.func.blacklist'] = preg_split( '/\s*,\s*/', (string) ini_get( 'suhosin.executor.func.blacklist' ) );
    598598            }
    599            
     599
    600600            if ( in_array( $function, $GLOBALS['it_classes_cached_values']['ini_get:suhosin.executor.func.blacklist'] ) ) {
    601601                return false;
    602602            }
    603            
     603
    604604            return true;
    605605        }
  • ithemes-exchange/trunk/lib/classes/load.php

    r1326981 r1523269  
    33/*
    44Written by Chris Jean for iThemes.com
    5 Version 2.4.7
     5Version 2.4.8
    66*/
    77
    88
    9 $it_registration_list_version   = '2.4.7';
     9$it_registration_list_version   = '2.4.8';
    1010$it_registration_list_library   = 'classes';
    1111$it_registration_list_init_file = dirname( __FILE__ ) . '/init.php';
     
    2020        if ( ! isset( $wp_locale ) )
    2121            return;
    22        
    23        
     22
     23
    2424        $init_files = array();
    25        
     25
    2626        foreach ( (array) $GLOBALS['it_classes_registration_list'] as $library => $versions ) {
    2727            $max_version = '-10000';
    2828            $init_file = '';
    29            
     29
    3030            foreach ( (array) $versions as $version => $file ) {
    3131                if ( version_compare( $version, $max_version, '>' ) ) {
     
    3434                }
    3535            }
    36            
     36
    3737            if ( ! empty( $init_file ) )
    3838                $init_files[] = $init_file;
    3939        }
    40        
     40
    4141        unset( $GLOBALS['it_classes_registration_list'] );
    42        
     42
    4343        foreach ( (array) $init_files as $init_file )
    4444            require_once( $init_file );
    45        
     45
    4646        do_action( 'it_libraries_loaded' );
    4747    }
    48    
     48
    4949    global $wp_version;
    50    
     50
    5151    if ( version_compare( $wp_version, '2.9.7', '>' ) )
    5252        add_action( 'after_setup_theme', 'it_registration_list_init' );
  • ithemes-exchange/trunk/readme.txt

    r1512896 r1523269  
    33Tags: ecommerce
    44Requires at least: 3.7
    5 Tested up to: 4.6
    6 Stable tag: 1.35.11
     5Tested up to: 4.7
     6Stable tag: 1.36.0
    77License: GPLv2 or later
    88
     
    8888
    8989== Changelog ==
     90
     91= 1.36.0 =
     92* Update: Updating lib/classes to v2.4.8
    9093
    9194= 1.35.11 =
Note: See TracChangeset for help on using the changeset viewer.