Making WordPress.org


Ignore:
Timestamp:
03/09/2026 06:37:33 AM (7 months ago)
Author:
dd32
Message:

PHP 8.4 compatibility: Various fixes to avoid PHP Deprecated warnings.

Includes an update of adhocore-php/jwt.

Merges ​https://github.com/WordPress/wordpress.org/pull/557

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/photo-directory/inc/photo.php

    r14650 r14681  
    386386                foreach ( array( 'title', 'caption', 'credit', 'copyright', 'camera', 'iso' ) as $key ) {
    387387                        if ( $meta[ $key ] && ! seems_utf8( $meta[ $key ] ) ) {
    388                                 $meta[ $key ] = utf8_encode( $meta[ $key ] );
     388                                $meta[ $key ] = mb_convert_encoding( $meta[ $key ], 'UTF-8', 'ISO-8859-1' );
    389389                        }
    390390                }
    … …  
    392392                foreach ( $meta['keywords'] as $key => $keyword ) {
    393393                        if ( ! seems_utf8( $keyword ) ) {
    394                                 $meta['keywords'][ $key ] = utf8_encode( $keyword );
     394                                $meta['keywords'][ $key ] = mb_convert_encoding( $keyword, 'UTF-8', 'ISO-8859-1' );
    395395                        }
    396396                }
    … …  
    991991
    992992                if ( $text && ! seems_utf8( $text ) ) {
    993                         $text = utf8_encode( $text );
     993                        $text = mb_convert_encoding( $text, 'UTF-8', 'ISO-8859-1' );
    994994                }
    995995
Note: See TracChangeset for help on using the changeset viewer.