Skip to content

Failed to convert "㎡" using mb_convert_encoding #17238

@da-inoue

Description

@da-inoue

Description

The PHP code below was saved as "character code: EUC-JP" and executed on the server with "mb_internal_encoding: EUC-JP".
The result is below.

I was hoping that the shift-jis encoding would display "㎡", but in "PHP 8.4.2" it did not work as expected.
I would like to know whether the change in behavior is a specification change or a bug.

The following code:

<?php
echo mb_convert_encoding('' ,"shift-jis", "euc-jp");

Resulted in this output:

「?」

But I expected this output instead:

「㎡」

PHP Version

PHP 8.4.2

Operating System

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions