Changeset 3367153
- Timestamp:
- 09/24/2025 11:48:32 AM (6 months ago)
- Location:
- shortpixel-adaptive-images
- Files:
-
- 8 edited
- 1 copied
-
tags/3.11.1 (copied) (copied from shortpixel-adaptive-images/trunk)
-
tags/3.11.1/includes/controllers/regex-parser.class.php (modified) (1 diff)
-
tags/3.11.1/includes/controllers/short-pixel-ai.class.php (modified) (1 diff)
-
tags/3.11.1/readme.txt (modified) (2 diffs)
-
tags/3.11.1/short-pixel-ai.php (modified) (2 diffs)
-
trunk/includes/controllers/regex-parser.class.php (modified) (1 diff)
-
trunk/includes/controllers/short-pixel-ai.class.php (modified) (1 diff)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/short-pixel-ai.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
shortpixel-adaptive-images/tags/3.11.1/includes/controllers/regex-parser.class.php
r3340495 r3367153 1061 1061 return $srcset; 1062 1062 } 1063 if(strpos($srcsetItem, $aiUrlBase) !== false || strpos($srcsetItem, $aiUrlBaseAmazon) !== false || strpos($srcsetItem, 'data:image/') === 0) { 1063 if( 1064 strpos($srcsetItem, $aiUrlBase) !== false 1065 || (!empty($aiUrlBaseAmazon) && strpos($srcsetItem, $aiUrlBaseAmazon) !== false) 1066 || strpos($srcsetItem, 'data:image/') === 0 1067 ) { 1064 1068 SHORTPIXEL_AI_DEBUG && $this->logger->log("REPLACE SRCSET abort - AI url: " . $srcsetItem); 1065 1069 return $srcset; //already parsed by the hook. 1066 1070 } 1067 $prefix = strpos($aiUrl, 'http') === 0 ? '' : 'http:'; 1068 $aiSrcsetItems[] = $prefix . $aiUrl .'/' . ShortPixelUrlTools::absoluteUrl(trim($srcsetItem)); 1071 // now we get ugly cdn url like this: 1072 // srcset="https://cdn.shortpixel.ai/spai/q_lossy+ret_img+to_webp/https://calin.shortpixel.com/wp-content/uploads/2025/02/image00031-1024x576.jpg 1024w 1073 // so we need to strip scheme from middle of url(origin) https://cdn.shortpixel.ai/spai/.../https://.... 1074 $parts = explode(' ', $srcsetItem, 2); 1075 $url = trim($parts[0]); 1076 $desc = isset($parts[1]) ? ' ' . trim($parts[1]) : ''; 1077 1078 $abs = ShortPixelUrlTools::absoluteUrl($url); 1079 1080 $u = parse_url($abs); 1081 $host = isset($u['host']) ? $u['host'] : ''; 1082 $path = isset($u['path']) ? $u['path'] : ''; 1083 $query = isset($u['query']) ? ('?' . $u['query']) : ''; 1084 1085 $absNoScheme = $host . $path . $query; 1086 1087 $prefix = (strpos($aiUrl, 'http') === 0) ? '' : 'http:'; 1088 $aiSrcsetItems[] = $prefix . $aiUrl . '/' . $absNoScheme . $desc; 1069 1089 } 1070 1090 return implode(', ', $aiSrcsetItems); -
shortpixel-adaptive-images/tags/3.11.1/includes/controllers/short-pixel-ai.class.php
r3340495 r3367153 2017 2017 ? $this->settings->exclusions->excluded_paths 2018 2018 : $this->settings->exclusions->eager_paths; 2019 if ( strlen($list)) {2019 if (!empty($list)) { 2020 2020 if ($this->isExcluded($url, $list) || $this->isExcluded($normalizedUrl, $list)) { 2021 2021 return true; -
shortpixel-adaptive-images/tags/3.11.1/readme.txt
r3340495 r3367153 5 5 Tested up to: 6.8 6 6 Requires PHP: 5.6.40 7 Stable tag: 3.11. 07 Stable tag: 3.11.1 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 249 249 250 250 == Changelog == 251 252 = 3.11.1 = 253 254 🔧 The Compatibility & CDN Sync Update 255 256 Release Date: September 24, 2025 257 258 🛠️ Fixes & Improvements 259 260 * PHP 8.4 Compatibility: Fixed a deprecation warning that appeared when running the plugin on PHP 8.4, ensuring smooth operation with the latest PHP versions. 261 * Better CDN Replacement: Ensured that all image links (including those in both src and srcset attributes, when "BOTH" is selected from the settings) are now consistently replaced with their CDN counterparts for optimal delivery. 262 263 Update now to improve compatibility and get consistent, CDN-powered performance across your site! 🚀 251 264 252 265 = 3.11.0 = -
shortpixel-adaptive-images/tags/3.11.1/short-pixel-ai.php
r3340495 r3367153 4 4 * Plugin URI: https://shortpixel.com/ 5 5 * Description: Display properly sized, smart cropped and optimized images on your website. Images are processed on the fly and served from our CDN. 6 * Version: 3.11. 06 * Version: 3.11.1 7 7 * Author: ShortPixel 8 8 * GitHub Plugin URI: https://github.com/short-pixel-optimizer/shortpixel-adaptive-images … … 16 16 17 17 if ( !class_exists( 'ShortPixelAI' ) ) { 18 define( 'SHORTPIXEL_AI_VERSION', '3.11. 0' );18 define( 'SHORTPIXEL_AI_VERSION', '3.11.1' ); 19 19 define( 'SPAI_SNIP_VERSION', '3.1.0' ); 20 20 define( 'SHORTPIXEL_AI_VANILLAJS_VER', '1.1' ); -
shortpixel-adaptive-images/trunk/includes/controllers/regex-parser.class.php
r3340495 r3367153 1061 1061 return $srcset; 1062 1062 } 1063 if(strpos($srcsetItem, $aiUrlBase) !== false || strpos($srcsetItem, $aiUrlBaseAmazon) !== false || strpos($srcsetItem, 'data:image/') === 0) { 1063 if( 1064 strpos($srcsetItem, $aiUrlBase) !== false 1065 || (!empty($aiUrlBaseAmazon) && strpos($srcsetItem, $aiUrlBaseAmazon) !== false) 1066 || strpos($srcsetItem, 'data:image/') === 0 1067 ) { 1064 1068 SHORTPIXEL_AI_DEBUG && $this->logger->log("REPLACE SRCSET abort - AI url: " . $srcsetItem); 1065 1069 return $srcset; //already parsed by the hook. 1066 1070 } 1067 $prefix = strpos($aiUrl, 'http') === 0 ? '' : 'http:'; 1068 $aiSrcsetItems[] = $prefix . $aiUrl .'/' . ShortPixelUrlTools::absoluteUrl(trim($srcsetItem)); 1071 // now we get ugly cdn url like this: 1072 // srcset="https://cdn.shortpixel.ai/spai/q_lossy+ret_img+to_webp/https://calin.shortpixel.com/wp-content/uploads/2025/02/image00031-1024x576.jpg 1024w 1073 // so we need to strip scheme from middle of url(origin) https://cdn.shortpixel.ai/spai/.../https://.... 1074 $parts = explode(' ', $srcsetItem, 2); 1075 $url = trim($parts[0]); 1076 $desc = isset($parts[1]) ? ' ' . trim($parts[1]) : ''; 1077 1078 $abs = ShortPixelUrlTools::absoluteUrl($url); 1079 1080 $u = parse_url($abs); 1081 $host = isset($u['host']) ? $u['host'] : ''; 1082 $path = isset($u['path']) ? $u['path'] : ''; 1083 $query = isset($u['query']) ? ('?' . $u['query']) : ''; 1084 1085 $absNoScheme = $host . $path . $query; 1086 1087 $prefix = (strpos($aiUrl, 'http') === 0) ? '' : 'http:'; 1088 $aiSrcsetItems[] = $prefix . $aiUrl . '/' . $absNoScheme . $desc; 1069 1089 } 1070 1090 return implode(', ', $aiSrcsetItems); -
shortpixel-adaptive-images/trunk/includes/controllers/short-pixel-ai.class.php
r3340495 r3367153 2017 2017 ? $this->settings->exclusions->excluded_paths 2018 2018 : $this->settings->exclusions->eager_paths; 2019 if ( strlen($list)) {2019 if (!empty($list)) { 2020 2020 if ($this->isExcluded($url, $list) || $this->isExcluded($normalizedUrl, $list)) { 2021 2021 return true; -
shortpixel-adaptive-images/trunk/readme.txt
r3340495 r3367153 5 5 Tested up to: 6.8 6 6 Requires PHP: 5.6.40 7 Stable tag: 3.11. 07 Stable tag: 3.11.1 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 249 249 250 250 == Changelog == 251 252 = 3.11.1 = 253 254 🔧 The Compatibility & CDN Sync Update 255 256 Release Date: September 24, 2025 257 258 🛠️ Fixes & Improvements 259 260 * PHP 8.4 Compatibility: Fixed a deprecation warning that appeared when running the plugin on PHP 8.4, ensuring smooth operation with the latest PHP versions. 261 * Better CDN Replacement: Ensured that all image links (including those in both src and srcset attributes, when "BOTH" is selected from the settings) are now consistently replaced with their CDN counterparts for optimal delivery. 262 263 Update now to improve compatibility and get consistent, CDN-powered performance across your site! 🚀 251 264 252 265 = 3.11.0 = -
shortpixel-adaptive-images/trunk/short-pixel-ai.php
r3340495 r3367153 4 4 * Plugin URI: https://shortpixel.com/ 5 5 * Description: Display properly sized, smart cropped and optimized images on your website. Images are processed on the fly and served from our CDN. 6 * Version: 3.11. 06 * Version: 3.11.1 7 7 * Author: ShortPixel 8 8 * GitHub Plugin URI: https://github.com/short-pixel-optimizer/shortpixel-adaptive-images … … 16 16 17 17 if ( !class_exists( 'ShortPixelAI' ) ) { 18 define( 'SHORTPIXEL_AI_VERSION', '3.11. 0' );18 define( 'SHORTPIXEL_AI_VERSION', '3.11.1' ); 19 19 define( 'SPAI_SNIP_VERSION', '3.1.0' ); 20 20 define( 'SHORTPIXEL_AI_VANILLAJS_VER', '1.1' );
Note: See TracChangeset
for help on using the changeset viewer.