Changeset 2901082
- Timestamp:
- 04/19/2023 08:53:06 AM (3 years ago)
- Location:
- supapress/trunk
- Files:
-
- 7 edited
-
admin/admin.php (modified) (1 diff)
-
composer.json (modified) (1 diff)
-
includes/controller.php (modified) (2 diffs)
-
includes/functions.php (modified) (1 diff)
-
includes/widget.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
-
supapress.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
supapress/trunk/admin/admin.php
r2877946 r2901082 362 362 $returnResults = array(); 363 363 foreach ( explode( ',', $ISBNs ) as $isbn ) { 364 if ( preg_match( '/^ 9([0-9]{12})$/', $isbn ) ) {364 if ( preg_match( '/^([0-9]{13})$/', $isbn ) ) { 365 365 $returnResults[ $isbn ] = array( 'title' => 'ISBN not found', 'found' => - 1 ); 366 366 } -
supapress/trunk/composer.json
r2877946 r2901082 3 3 "description": "Quickly and easily connect your book metadata (ONIX) to your WordPress site.", 4 4 "type": "wordpress-plugin", 5 "version": "2.23. 0",5 "version": "2.23.1", 6 6 "authors": [ 7 7 { -
supapress/trunk/includes/controller.php
r2303372 r2901082 146 146 147 147 if ( $part === '%isbn13%' ) { 148 $part = '( 9\d{12})';148 $part = '(\d{13})'; 149 149 } elseif ( in_array( $part, $genericPlaceholders ) ) { 150 150 $part = '([^\/]+)'; 151 151 } else { 152 $part = str_replace( '%isbn13%', '( 9\d{12})', $part );152 $part = str_replace( '%isbn13%', '(\d{13})', $part ); 153 153 $part = str_replace( $genericPlaceholders, '([^\/]+)', $part ); 154 154 } … … 158 158 159 159 // Build temp URL from new rule so we can check where the ISBN match will be 160 $tempUrl = str_replace( '( 9\d{12})', '9998887770001', $newRule );160 $tempUrl = str_replace( '(\d{13})', '9998887770001', $newRule ); 161 161 $tempUrl = str_replace( '([^\/]+)', 'temp', $tempUrl ); 162 162 -
supapress/trunk/includes/functions.php
r2856087 r2901082 978 978 979 979 // check that the ISBN is set 980 if( preg_match( '/ ^9\d{12}$/', get_query_var( 'supapress_isbn' ) ) === '' ) {980 if( preg_match( '/\d{13}$/', get_query_var( 'supapress_isbn' ) ) === '' ) { 981 981 return; 982 982 } -
supapress/trunk/includes/widget.php
r2877946 r2901082 361 361 } 362 362 } elseif ( $this->properties['widget_type'] === 'product_details' ) { 363 if ( preg_match( '/ 9\d{12}/', get_query_var( 'supapress_isbn' ) ) ) {363 if ( preg_match( '/\d{13}/', get_query_var( 'supapress_isbn' ) ) ) { 364 364 $service = 'book/' . get_query_var( 'supapress_isbn' ); 365 365 $params = array(); -
supapress/trunk/readme.txt
r2877946 r2901082 3 3 Tags: supadü, supadu, folio, books, publishers, supafolio, supadu for wordpress, supapress, supafolio for wordpress 4 4 Requires at least: 6.0 5 Tested up to: 6. 16 Stable tag: 2.23. 05 Tested up to: 6.2 6 Stable tag: 2.23.1 7 7 License: GPLv2 or later 8 8 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 38 38 39 39 == Changelog == 40 41 = 2.23.1 = 42 Release Date: April 2023 43 * Fix: preg_match for isbn13 fixed 40 44 41 45 = 2.23.0 = -
supapress/trunk/supapress.php
r2877946 r2901082 7 7 * Plugin URI: https://www.supadu.com 8 8 * Description: Quickly and easily connect your book metadata (ONIX) to your WordPress site. 9 * Version: 2.23. 09 * Version: 2.23.1 10 10 * Author: Supadü 11 11 * Author URI: https://www.supadu.com … … 37 37 defined( 'ABSPATH' ) or die( 'Illegal Access!' ); 38 38 39 define( 'SUPAPRESS_VERSION', '2.23. 0' );39 define( 'SUPAPRESS_VERSION', '2.23.1' ); 40 40 41 41 define( 'SUPAPRESS_SITE_URL', get_site_url() );
Note: See TracChangeset
for help on using the changeset viewer.