php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #64477 Special characters - UTF-8 - Windows - Console
Submitted: 2013-03-21 12:57 UTC Modified: 2013-03-21 15:59 UTC
From: faca5 at volja dot net Assigned: ab (profile)
Status: Closed Package: *General Issues
PHP Version: 5.4.13 OS: Windows
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: faca5 at volja dot net
New email:
PHP Version: OS:

 

 [2013-03-21 12:57 UTC] faca5 at volja dot net
Description:
------------
Hello.

I have problem with running php script in Windows console. It do not display correct characters!

Same with using "chcp 65001"

Test script:
---------------
<?= "ščž"; ?>

Expected result:
----------------
ščž

Actual result:
--------------
i╗?A!─?A3

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2013-03-21 15:59 UTC] ab@php.net
That's clearly not PHP but a terminal issue. On windows its limited to the terminal fonts and depends also on whether the terminal has the multibyte support. I've saved your snippet as UTF-8 and was able to see two of that three chars in powershell chcp 65001 on win8, the normal cmd seems to have no multibyte support. Or maybe you could try to tweak the fonts in the registry, not sure.
 [2013-03-21 15:59 UTC] ab@php.net
-Status: Open +Status: Closed -Assigned To: +Assigned To: ab
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Tue May 06 23:01:28 2025 UTC