Plugin Directory

Changeset 2258139


Ignore:
Timestamp:
03/10/2020 11:58:42 AM (6 years ago)
Author:
greencp
Message:

v2.3: serve image method "WP 404 handler" added, jit support for WP 5.3.2 added

Location:
wp-performance-pack/trunk
Files:
1 added
11 edited

Legend:

Unmodified
Added
Removed
  • wp-performance-pack/trunk/admin/class.admin-renderer.php

    r2255068 r2258139  
    1717        switch ( $modname ) {
    1818            case 'cdn_support'      : return __( 'CDN Support', 'wp-performance-pack' );
    19             case 'disable_widgets'  : return __( 'Widgets (BETA)', 'wp-performance-pack' );
     19            case 'disable_widgets'  : return __( 'Widgets', 'wp-performance-pack' );
    2020            case 'dynamic_images'   : return __( 'Images', 'wp-performance-pack' );
    2121            case 'l10n_improvements': return __( 'Localization', 'wp-performance-pack' );
     
    2929        switch ( $modname ) {
    3030            case 'cdn_support'      : return __( 'Serve images through CDN. Applies to images on both Frontend (what visitors see) and Backend (your Dashboard).', 'wp-performance-pack' );
    31             case 'disable_widgets'  : return __( 'Disable WordPress default widgets.', 'wp-performance-pack' );
     31            case 'disable_widgets'  : return __( "Disable WordPress' default widgets.", 'wp-performance-pack' );
    3232            case 'dynamic_images'   : return __( 'Improve WordPress image handling by creating intermediate images (thumbnails) on demand.', 'wp-performance-pack' );
    3333            case 'l10n_improvements': return __( 'Improve performance of WordPress localization by using native gettext or alternative MO file reader, disabling back end translation and just in time localization of scripts.', 'wp-performance-pack' );
  • wp-performance-pack/trunk/modules/disable_widgets/class.wppp_disable_widgets_advanced.php

    r2214271 r2258139  
    2727    ?>
    2828        <style>.form-table th, .form-table td { padding : 10px 10px }</style>
    29         <h3 class="title"><?php _e( 'WordPress default widgets', 'wp-performance-pack' );?></h3>
     29        <h3 class="title"><?php _e( "WordPress' default widgets", 'wp-performance-pack' );?></h3>
    3030        <p><strong>Really</strong> disable WordPress' default widgets. This feature is still in beta so be careful. Please report any issues in the support forums.</p>
    3131
  • wp-performance-pack/trunk/modules/dynamic_images/class.wppp_dynamic_images.php

    r2250533 r2258139  
    4949            $this->rw_folder = $output[ 'dynamic_images_thumbfolder' ] && !$output[ 'dynamic_images_nosave' ];
    5050            $this->rw_method = $output[ 'dynimg_serve_method' ];
    51             $this->flush_rewrite_rules( $output[ 'dynamic_images' ] );
     51            $this->flush_rewrite_rules( $output[ 'dynamic_images' ] && $output[ 'dynimg_serve_method' ] !== 'wordpress' );
    5252        }
    5353        return $output;
     
    5555   
    5656    function early_init () {
    57         if ( $this->wppp->is_network ) {
     57        if ( $this->wppp->is_network && $this->wppp->options[ 'dynimg_serve_method' ] !== 'wordpress' ) {
    5858            add_action( 'setup_theme',  array( $this, 'replace_wp_rewrite' ) );
    5959        }
     
    9292
    9393    public function set_rewrite_rules() {
    94         if ( $this->rw_method === 'use_themes' ) {
    95             $file = 'serve-dynamic-images-ut.php';
    96         } else {
    97             $file = 'serve-dynamic-images.php';
    98         }
    99         $path = substr( plugins_url( $file, __FILE__ ), strlen( site_url() ) + 1 ); // cut wp-content including trailing slash
    100         add_rewrite_rule( '(.*)-([0-9]+)x([0-9]+)?\.((?i)jpeg|jpg|png|gif)' , $path, 'top' );
    101         add_filter ( 'mod_rewrite_rules', array ( $this, 'mod_rewrite_rules' ) );
     94        if ( $this->rw_method === 'wordpress' ) {
     95            add_filter( 'pre_handle_404', array( $this, 'handle_404' ), 10, 2 );
     96        } else {
     97            if ( $this->rw_method === 'use_themes' ) {
     98                $file = 'serve-dynamic-images-ut.php';
     99            } else {
     100                $file = 'serve-dynamic-images.php';
     101            }
     102            $path = substr( plugins_url( $file, __FILE__ ), strlen( site_url() ) + 1 ); // cut wp-content including trailing slash
     103            add_rewrite_rule( '(.*)-([0-9]+)x([0-9]+)?\.((?i)jpeg|jpg|png|gif)' , $path, 'top' );
     104            add_filter ( 'mod_rewrite_rules', array ( $this, 'mod_rewrite_rules' ) );
     105        }
     106    }
     107
     108    public function handle_404( $bool, $wp_query ) {
     109        global $wp;
     110        $serve = new WPPP_Serve_Image();
     111        if ( $serve->serve_image( trailingslashit( parse_url( get_site_url() )[ 'path' ] ) . $wp->request ) )
     112            exit(); // Image got served, so exit at this point
     113        else
     114            return false; // continue 404 handling
    102115    }
    103116
  • wp-performance-pack/trunk/modules/dynamic_images/class.wppp_dynamic_images_advanced.php

    r2240498 r2258139  
    1515        ) );
    1616        $screen->add_help_tab( array(
    17             'id'    => 'wppp_advanced_exif',
    18             'title' => __( 'EXIF thumbs', 'wp-performance-pack' ),
    19             'content'   => '<p>' . __( "Usage of EXIF thumbs for thumbnail creation improves peformance when creating small thumbs. If the intermediate image size is smaller than the size of the EXIF thumbnail, the EXIF image will be used for resizing instead of the full image, which is way faster and less memory intense. But be aware that EXIF thumbs might differ from the actual image, depending on the editing software used to create the image.", 'wp-performance-pack' ) . '</p>'
    20         ) );
    21         $screen->add_help_tab( array(
    2217            'id'    => 'wppp_advanced_servemethod',
    2318            'title' => __( 'Serve method', 'wp-performance-pack' ),
    24             'content'   => '<p>' . __( "Dynamic images can be served using one of two methods which differ in how much of WordPress will be loaded. <em>SHORTINIT</em> will only load the WordPress core, no themes or plugins and is the faster of both options. <em>WP_USE_THEMES</em> will load core and plugins, but not the theme files. That way other image processing plugins will be loaded and used when images get resized (if they are based on WP_Image_Editor).", 'wp-performance-pack' ) . '</p>'
     19            'content'   => '<p>' . __( "Dynamic images can be served using different methods which differ in how much of WordPress will be loaded. <ul><li><em>WordPress 404 handler</em> - Uses WordPress' internal 404 handling to create intermediate images. Using permalinks is required but no additional rewrite rules are created. This is the slowest and most compatible method.</li><li><em>Compatible rewrite</em> - Uses own rewrite rules to create intermediate images. Loads WordPress core and plugins but not the theme (using <code>WP_USE_THEMES</code>). This allows usage of other image processing plugins for image resizing (if they are based on WP_Image_Editor).</li><li><em>Rewrite fast</em> - Fastest method to create intermediate images. Uses own rewrite rules and <code>SHORT_INIT</code> to only load WordPress' core.</li></ul>", 'wp-performance-pack' ) . '</p>'
    2520        ) );
    2621        $screen->add_help_tab( array(
     
    3025        ) );
    3126        $screen->add_help_tab( array(
     27            'id'    => 'wppp_advanced_exif',
     28            'title' => __( 'EXIF thumbs', 'wp-performance-pack' ),
     29            'content'   => '<p>' . __( "Usage of EXIF thumbs for thumbnail creation improves peformance when creating small thumbs. If the intermediate image size is smaller than the size of the EXIF thumbnail, the EXIF image will be used for resizing instead of the full image, which is way faster and less memory intense. But be aware that EXIF thumbs might differ from the actual image, depending on the editing software used to create the image.", 'wp-performance-pack' ) . '</p>'
     30        ) );
     31        $screen->add_help_tab( array(
    3232            'id'    => 'wppp_advanced_rewriterules',
    3333            'title' => __( 'Inherit rewrite rules', 'wp-performance-pack' ),
    34             'content'   => '<p>' . __( 'Add <code>RewriteOption InheritDownBefore</code> to WPPPs rewrite rules.', 'wp-performance-pack' ) . '</p><p>' . __( "Some plugins (e.g. WebP Express) place override rewrite rules by placing .htaccess files in sub directories of your WordPress installation that can disable WPPPs rewrite rules for dynamic image generation.", 'wp-performance-pack' ) . '</p><p>' . __( "By enabling this option the base rewrite rules (not just WPPPs, but all defined in the .htaccess file in your WordPess installations base path) will be inherited by all sub directories of your installation, thus reenabling dynamic image vreation by WPPP", 'wp-performance-pack' ) . '</p>'
     34            'content'   => '<p>' . __( 'Add <code>RewriteOption InheritDownBefore</code> to WPPPs rewrite rules.', 'wp-performance-pack' ) . '</p><p>' . __( "Some plugins (e.g. WebP Express) place override rewrite rules by placing .htaccess files in sub directories of your WordPress installation that can disable WPPPs rewrite rules for dynamic image generation. By enabling this option the base rewrite rules (not just WPPPs, but all defined in the .htaccess file in your WordPess installations base path) will be inherited by all sub directories of your installation, thus reenabling dynamic image creation by WPPP", 'wp-performance-pack' ) . '</p><p>' . __( 'Only applies if either "Compatible rewrite" or "Fast rewrite" is used as method.', 'wp-performance-pack' ) . '</p>'
    3535        ) );
    3636    }
     
    4747        <p class="description"><?php _e( "Create intermediate images on demand, not on upload. If you deactive dynamic image resizing after some time of usage you might have to recreate thumbnails using a plugin like Regenerate Thumbnails.", 'wp-performance-pack' ); ?></p>
    4848        <?php $this->do_hint_permalinks( true ); ?>
    49         <br/>
    50        
     49
    5150        <table class="form-table" style="clear:none">
    5251            <tr valign="top">
     52                <th scope="row"><?php _e( 'Serve image method', 'wp-performance-pack' ); ?></th>
     53                <td>
     54                    <p>
     55                        <select <?php $this->e_opt_name( 'dynimg_serve_method' ); ?> value="short_init">
     56                            <option value="wordpress" <?php echo ( $this->wppp->options[ 'dynimg_serve_method' ] === 'wordpress' ) ? 'selected="selected"' : ''; ?>><?php _e( 'WordPress 404 handler', 'wp-performance-pack' ); ?></option>
     57                            <option value="use_themes" <?php echo ( $this->wppp->options[ 'dynimg_serve_method' ] === 'use_themes' ) ? 'selected="selected"' : ''; ?>><?php _e( 'Compatible rewrite', 'wp-performance-pack' ); ?></option>
     58                            <option value="short_init" <?php echo ( $this->wppp->options[ 'dynimg_serve_method' ] === 'short_init' ) ? 'selected="selected"' : ''; ?>><?php _e( 'Fast rewrite', 'wp-performance-pack' );?></option>
     59                        </select>
     60                    </p>
     61                    <p class="description"><?php _e( 'Method used to dynamically create intermediate images. "WordPress 404 handler" is the slowest and most compatible. "Compatible rewrite" and "Fast rewrite" add extra rewrite rules to your .htaccess file.', 'wp-performance-pack' ); ?></p>
     62                    <br/>
     63                    <?php $this->e_checkbox( 'rewrite_inherit', 'rewrite_inherit', __( 'Inherit rewrite rules', 'wp-performance-pack' ) ); ?>
     64                    <p class="description"><?php _e( 'Add <code>RewriteOption InheritDownBefore</code> to WPPPs rewrite rules.', 'wp-performance-pack' ); ?> <?php _e( 'Only applies if either "Compatible rewrite" or "Fast rewrite" is used as method.', 'wp-performance-pack' ) ?></p>
     65                </td>
     66            </tr>
     67            <tr>
    5368                <th scope="row"><?php _e( 'Image saving', 'wp-performance-pack' ); ?></th>
    5469                <td>
    55                     <p><?php _e( 'Serve image method:', 'wp-performance-pack' ); ?>
    56                         <select <?php $this->e_opt_name( 'dynimg_serve_method' ); ?> value="short_init">
    57                             <option value="short_init" <?php echo ( $this->wppp->options[ 'dynimg_serve_method' ] === 'short_init' ) ? 'selected="selected"' : ''; ?>><?php _e( 'Fast', 'wp-performance-pack' );?></option>
    58                             <option value="use_themes" <?php echo ( $this->wppp->options[ 'dynimg_serve_method' ] === 'use_themes' ) ? 'selected="selected"' : ''; ?>><?php _e( 'Compatible', 'wp-performance-pack' ); ?></option>
    59                         </select>
    60                     </p>
    61                     <p class="description"><?php _e( 'Use <em>Fast</em> for faster image serving. No plugins will be loaded when serving images using this method. Use <em>Compatible</em> to make dynamic images compatible with other installed (image) plugins.', 'wp-performance-pack' ); ?></p>
    62                     <br/>
    6370                    <?php $this->e_checkbox( 'dynamic_images_nosave', 'dynamic_images_nosave', __( "Don't save images to disc", 'wp-performance-pack' ), !$this->is_dynamic_images_available() ); ?>
    6471                    <p class="description"><?php _e( 'Dynamically recreate intermediate images on each request.', 'wp-performance-pack' ); ?></p>
     
    105112                </td>
    106113            </tr>
    107             <tr valign="top">
    108                 <th scope="row"><?php _e( 'Inherit rewrite rules', 'wp-performance-pack' ); ?></th>
    109                 <td>
    110                     <?php $this->e_switchButton( 'rewrite_inherit' ); ?>
    111                     <p class="description"><?php _e( 'Add "RewriteOption InheritDownBefore" to WPPPs rewrite rules.', 'wp-performance-pack' ); ?></p>
    112                 </td>
    113             </tr>
    114114        </table>
    115115
  • wp-performance-pack/trunk/modules/dynamic_images/class.wppp_serve_image.php

    r2241623 r2258139  
    5151     */
    5252    function exit404( $message ) {
    53         header( $_SERVER[ 'SERVER_PROTOCOL' ] . ' 404 Not Found' );
    54         header( 'Cache-Control: no-cache, must-revalidate' );   // HTTP/1.1
    55         header( 'Expires: Sat, 26 Jul 1997 05:00:00 GMT' );     // past date
    56         echo $message;
    57         exit();
    5853    }
    5954
     
    7570            $this->localfilename    = $uploads_dir['basedir'] . $findfile;
    7671            $this->localfiletime    = filemtime( $this->localfilename );
    77             if ( !file_exists( $this->localfilename ) )
     72
     73            if ( !file_exists( $this->localfilename ) ) {
    7874                $this->exit404( 'File "' . $this->localfilename . '" not found' );
     75                return false;
     76            }
    7977            $findfile                   = str_replace( $upload_path, '', $this->filename_scaled );
    8078            $this->localfilename_scaled = $uploads_dir['basedir'] . $findfile;
    8179        }
    82     }
    83 
    84     function init() {
    85         if ( !preg_match( '/(.*)-([0-9]+)x([0-9]+)?\.(jpeg|jpg|png|gif)/i', $_SERVER[ 'REQUEST_URI' ], $matches ) )
     80        return true;
     81    }
     82
     83    function init( $request ) {
     84        if ( !preg_match( '/(.*)-([0-9]+)x([0-9]+)?\.(jpeg|jpg|png|gif)/i', $request, $matches ) ) {
    8685            $this->exit404( 'No file match' );
    87 
     86            return false;
     87        }
    8888        $this->filename = urldecode( $matches[ 1 ] . '.' . $matches[ 4 ] );
    8989        $this->filename_scaled = urldecode( $matches[ 1 ] . '-scaled.' . $matches[ 4 ] ); //TODO: find a better way to get scaled name as this wont adapt well to changes in name for scaled images
    9090        $this->width = $matches[ 2 ];
    9191        $this->height = $matches[ 3 ];
    92 
    93         // search and load wp-load.php
    94         $folder = dirname( __FILE__ );
    95         while ( $folder != dirname( $folder ) ) {
    96             if ( file_exists( $folder . '/wp-load.php' ) ) {
    97                 break;
    98             } else {
    99                 $folder = dirname( $folder );
    100             }
    101         }
    102         require( $folder . '/wp-load.php' ); // will fail if while loop didn't find wp-load.php
    103         unset( $folder );
    104 
    105         add_filter( 'wp_image_editors', array ( $this, 'filter_wp_image_editor' ), 1000, 1 ); // set to very low priority, so it is hopefully called last as this overrides previously registered editors
     92        return true;
    10693    }
    10794
     
    10996        global $wp_performance_pack;
    11097        $this->wppp = $wp_performance_pack;
    111         $this->wppp->load_options();
    112         if ( $this->wppp->options[ 'dynamic_images' ] !== true )
    113             $this->exit404( 'WPPP dynamic images deactivated for this site' );
    11498    }
    11599
     
    145129    }
    146130
    147     function serve_image() {
    148         $this->init();
     131    function serve_image( $request ) {
     132        if ( !$this->init( $request ) )
     133            return false;
     134
     135        add_filter( 'wp_image_editors', array ( $this, 'filter_wp_image_editor' ), 1000, 1 ); // set to very low priority, so it is hopefully called last as this overrides previously registered editors
     136
    149137        $this->load_wppp();
    150         $this->get_local_filename();
     138
     139        if ( !$this->get_local_filename() )
     140            return false;
     141
    151142        if ( $this->wppp->options[ 'dynamic_images_nosave' ] && function_exists( 'apache_request_headers' ) ) {
    152143            // Only check request headers if nosave option is enabled. Else server_image shouldn't be called twice for the same image.
     
    167158            // that's why they are stored as an option
    168159            $image = wp_get_image_editor( $this->localfilename );
    169             if ( is_wp_error( $image ) )
     160            if ( is_wp_error( $image ) ) {
    170161                $this->exit404( 'Error loading image' );
     162                return fasle;
     163            }
    171164            $imgsize = $image->get_size();
    172165
     
    185178            }
    186179
    187             if ( $the_size === '' )
     180            if ( $the_size === '' ) {
    188181                $this->exit404( 'Unknown image size' );
     182                return false;
     183            }
    189184            unset( $sizes );
    190185
     
    257252                echo $data[ 'data' ];
    258253            unset( $image );
     254            return true;
    259255        } catch ( Exception $e ) {
    260256            unset( $image );
  • wp-performance-pack/trunk/modules/dynamic_images/serve-dynamic-images-ut.php

    r1679301 r2258139  
    1111
    1212class WPPP_Serve_Image_UT extends WPPP_Serve_Image {
    13     function init() {
     13
     14    function init( $request ) {
    1415        define( 'WP_USES_THEMES', false );
    15         parent::init();
     16        parent::init( $request );
     17
     18        // search and load wp-load.php
     19        $folder = dirname( __FILE__ );
     20        while ( $folder != dirname( $folder ) ) {
     21            if ( file_exists( $folder . '/wp-load.php' ) ) {
     22                break;
     23            } else {
     24                $folder = dirname( $folder );
     25            }
     26        }
     27        require( $folder . '/wp-load.php' ); // will fail if while loop didn't find wp-load.php
     28        unset( $folder );
     29
     30        return true;
     31    }
     32
     33    function exit404( $message ) {
     34        header( $_SERVER[ 'SERVER_PROTOCOL' ] . ' 404 Not Found' );
     35        header( 'Cache-Control: no-cache, must-revalidate' );   // HTTP/1.1
     36        header( 'Expires: Sat, 26 Jul 1997 05:00:00 GMT' );     // past date
     37        echo $message;
     38        exit();
     39    }
     40
     41    function load_wppp() {
     42        global $wp_performance_pack;
     43        $this->wppp = $wp_performance_pack;
     44        $this->wppp->load_options();
     45        if ( $this->wppp->options[ 'dynamic_images' ] !== true )
     46            $this->exit404( 'WPPP dynamic images deactivated for this site' );
    1647    }
    1748}
    1849
    1950$serve = new WPPP_Serve_Image_UT();
    20 $serve->serve_image();
     51$serve->serve_image(  $_SERVER[ 'REQUEST_URI' ] );
  • wp-performance-pack/trunk/modules/dynamic_images/serve-dynamic-images.php

    r1679301 r2258139  
    1111
    1212class WPPP_Serve_Image_SI extends WPPP_Serve_Image {
    13     function init() {
     13
     14    function exit404( $message ) {
     15        header( $_SERVER[ 'SERVER_PROTOCOL' ] . ' 404 Not Found' );
     16        header( 'Cache-Control: no-cache, must-revalidate' );   // HTTP/1.1
     17        header( 'Expires: Sat, 26 Jul 1997 05:00:00 GMT' );     // past date
     18        echo $message;
     19        exit();
     20    }
     21
     22    function init( $request ) {
    1423        define( 'SHORTINIT', true );
     24        parent::init( $request );
    1525
    16         parent::init();
     26        // search and load wp-load.php
     27        $folder = dirname( __FILE__ );
     28        while ( $folder != dirname( $folder ) ) {
     29            if ( file_exists( $folder . '/wp-load.php' ) ) {
     30                break;
     31            } else {
     32                $folder = dirname( $folder );
     33            }
     34        }
     35        require( $folder . '/wp-load.php' ); // will fail if while loop didn't find wp-load.php
     36        unset( $folder );
    1737
    1838        // dummy add_shortcode required for media.php - we don't need any shortcodes so don't load that file and use a dummy instead
     
    2141        if ( is_multisite() )
    2242            require ( ABSPATH . 'wp-includes/ms-functions.php' );
     43
     44        return true;
    2345    }
    2446
    2547    function load_wppp() {
    2648        include( sprintf( "%s/wp-performance-pack.php", dirname( dirname( dirname( __FILE__ ) ) ) ) );
    27         parent::load_wppp();
     49
     50        global $wp_performance_pack;
     51        $this->wppp = $wp_performance_pack;
     52        $this->wppp->load_options();
     53        if ( $this->wppp->options[ 'dynamic_images' ] !== true )
     54            $this->exit404( 'WPPP dynamic images deactivated for this site' );
    2855
    2956        if ( !$this->wppp->options[ 'dynamic_images_nosave' ] ) {
     
    99126
    100127$serve = new WPPP_Serve_Image_SI();
    101 $serve->serve_image();
     128$serve->serve_image( $_SERVER[ 'REQUEST_URI' ] );
  • wp-performance-pack/trunk/modules/l10n_improvements/class.labelsobject.php

    r2255068 r2258139  
    2222    public function __construct( $args = NULL ) {
    2323        $params = func_get_args ();
    24         if ( isset ( $params[0] ) && is_callable ( $params[0] ) ) {
    25             $this->default_translate_func = $params[0];
     24        if ( isset( $params[ 0 ] ) && is_callable( $params[ 0 ] ) ) {
     25            $this->default_translate_func = $params[ 0 ];
    2626            $params = array_splice( $params, 1 );
    2727        }
    28         if (isset ( $params[0] ) && ( is_array ( $params[0] ) || $params[0] instanceof LabelsObject) ) {
    29             $this->merge( $params[0] );
     28        if ( isset( $params[ 0 ] ) && ( is_array( $params[ 0 ] ) || $params[ 0 ] instanceof LabelsObject) ) {
     29            $this->merge( $params[ 0 ] );
    3030        }
    3131    }
     
    3333    /* ArrayAccess methods */
    3434
    35     public function offsetExists ( $offset ) {
    36         return ( isset( $this->input[$offset] ) || isset( $this->output[$offset] ) );
     35    public function offsetExists( $offset ) {
     36        return ( isset( $this->input[ $offset ] ) || isset( $this->output[ $offset ] ) );
    3737    }
    3838
    39     public function offsetGet ( $offset ) {
     39    public function offsetGet( $offset ) {
    4040        if ( !isset( $this->output[$offset] ) && isset( $this->input[$offset] ) ) {
    4141            /* if outpt is not set but input is set there are only two possible options:
     
    119119    /* Other methos */
    120120
    121     public function merge ( $labels ) {
     121    public function merge( $labels ) {
    122122        if ( $labels instanceof LabelsObject ) {
    123123            foreach ( $labels->output as $key => $value ) {
     
    125125            }
    126126            foreach ( $labels->input as $key => $value ) {
    127                 if ( is_string ( $value ) ) {
     127                if ( is_string( $value ) ) {
    128128                    // a pure string only gets saved to input, if default_translate_func is specified
    129129                    if ( $labels->default_translate_func == $this->default_translate_func ) {
  • wp-performance-pack/trunk/modules/l10n_improvements/class.wppp_l10n_improvements.php

    r2255068 r2258139  
    88        '4.8'   => '4.8',
    99        '4.8.1' => '4.8.1',
     10        '5.3.2' => '5.3.2',
    1011    );
    1112
  • wp-performance-pack/trunk/readme.txt

    r2255068 r2258139  
    55Tested up to: 5.3.2
    66Requires PHP: 5.3
    7 Stable tag: 2.2.6
     7Stable tag: 2.3
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    128128== Changelog ==
    129129
     130= 2.3 =
     131* [dynimg] NEW! New method to dynamically create intermediate image sizes added: You can now use WordPress' internal 404 handling as method. This is slower but doesn't require any additional rewrite rules so it should work out of the box with any web server that supports WordPress permalinks (i.e. IIS).
     132* [jit] Support for WordPress 5.3.2 added.
     133* Fixed some typos.
     134
    130135= 2.2.6 =
    131136* [gettext] Improved error handling during test for native gettext support.
  • wp-performance-pack/trunk/wp-performance-pack.php

    r2255068 r2258139  
    44    Plugin URI: http://wordpress.org/plugins/wp-performance-pack
    55    Description: Performance optimizations for WordPress. Improve localization performance and image handling, serve images through CDN. 
    6     Version: 2.2.6
     6    Version: 2.3
    77    Text Domain: wp-performance-pack
    88    Author: Bj&ouml;rn Ahrens
     
    130130     * @const string
    131131     */
    132     const wppp_version = '2.2.6';
     132    const wppp_version = '2.3';
    133133
    134134    /**
     
    164164            'dynamic_images_exif_thumbs'    => array( 'default' => false, 'type' => 'bool' ),
    165165            'dynimg_quality'                => array( 'default' => 80, 'type' => 'int', 'min' => 10, 'max' => 100 ),
    166             'dynimg_serve_method'           => array( 'default' => 'short_init', 'type' => 'enum', 'values' => array( 'short_init', 'use_themes' ) ),
     166            'dynimg_serve_method'           => array( 'default' => 'wordpress', 'type' => 'enum', 'values' => array( 'short_init', 'use_themes', 'wordpress' ) ),
    167167            'exif_width'                    => array( 'default' => 320, 'type' => 'int' ),
    168168            'exif_height'                   => array( 'default' => 320, 'type' => 'int' ),
Note: See TracChangeset for help on using the changeset viewer.