Plugin Directory

Changeset 2893349


Ignore:
Timestamp:
04/04/2023 07:19:30 AM (3 years ago)
Author:
alordiel
Message:

fixes related to PHP8

Location:
dropdown-multisite-selector/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • dropdown-multisite-selector/trunk/dropdown-multisite-selector.php

    r2707718 r2893349  
    44 * Plugin URI:        https://wordpress.org/plugins/dropdown-multisite-selector/
    55 * Description:       Allows you to configure a select option of redirecting to different webpages.
    6  * Version:           0.9.1
     6 * Version:           0.9.2
    77 * Author:            alordiel
     8 * Requires PHP:      7.4.0
     9 * Requires at least: 3.8
    810 * Author URI:        http://profiles.wordpress.org/alordiel
    911 * Text Domain:       dropdown-multisite-selector
  • dropdown-multisite-selector/trunk/functions/functions.php

    r2707661 r2893349  
    118118    $search = array(
    119119        '@<script[^>]*?>.*?</script>@si',
    120         '@<[\/\!]*?[^<>]*?>@si',
     120        '@<[/!]*?[^<>]*?>@si',
    121121        '@<![\s\S]*?--[ \t\n\r]*>@'
    122122    );
     
    169169        }
    170170        if ( $i > mb_strlen( $b_string ) ) {
    171             return true;
     171            return 1;
    172172        }
    173 
    174         return ( mb_strpos( $alphabet, mb_substr( $a, $i, 1 ) ) > mb_strpos( $alphabet, mb_substr( $b, $i, 1 ) ) );
     173        $compared = ( mb_strpos( $alphabet, mb_substr( $a_string, $i, 1 ) ) > mb_strpos( $alphabet, mb_substr( $b_string, $i, 1 ) ) );
     174        return $compared ? 1 : -1;
    175175    }
    176176
    177     return false;
     177    return -1;
    178178}
    179179
     
    187187    $b_string = mb_strtolower( $b['name'] );
    188188
    189     return $a_string > $b_string;
     189    return $a_string > $b_string ? 1 : -1;
    190190}
  • dropdown-multisite-selector/trunk/readme.txt

    r2707718 r2893349  
    1  === Plugin Name ===
     1 === Dropdown Multisite selector ===
    22
    33Tags: multisite, dropdown menu, flexible select, edit select options, redirect
    44Requires at least: 3.8
    55Contributors: alordiel
    6 Tested up to: 5.9.3
    7 Stable tag: 0.9.1
     6Tested up to: 6.2.0
     7Stable tag: 0.9.2
     8Requires PHP: 7.4.0
    89License: GPLv2 or later
    910License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    6970
    7071== Changelog ==
     72
     73= 0.9.2 =
     74* Date: 03 Apr 2023
     75* [Fix] PHP8 deprecation notice
     76* [Fix] PHP8 fatal error on saving a content with [dms] shortcode (solved by @zodiac1978)
     77
    7178= 0.9.1 =
    7279* Date: 10 Apr 2022
    7380* [Fix] issue with dms_manual shortcode
    74 
    7581
    7682= 0.9.0 =
Note: See TracChangeset for help on using the changeset viewer.