The default encoding of phpstorm is utf-8. If you need other encodings in the project, you can change it like this: File-->Setting-->Editor (left)-- >File Encodings, then you can change the encoding.
Related recommendations: "PhpStorm Usage Tutorial"
But even if the encoding is set to utf-8 in the php page, it will still be garbled. At this time, you need to add the following sentence The words are spoken:
<?php header('Content-Type:textml;charset=utf-8'); //没错就是这句!!要放在输出之前
The above is the detailed content of What should I do if phpstorm Chinese displays garbled characters?. For more information, please follow other related articles on the PHP Chinese website!