search

Home  >  Q&A  >  body text

An error occurs when PHP url contains Chinese characters

The local environment is win10 xampp

The directory or file name where the php file is located has Chinese characters, such as f:wwwroot Chinese test.php

Resulting in an error when accessing http://localhost/中文/test.php

Warning: Unknown: failed to open stream: No such file or directory in Unknown on line 0

Fatal error: Unknown: Failed opening required 'F:/wwwroot/中文/test.php' (include_path='.;D:xamppphpPEAR') in Unknown on line 0

Changing the directory name to English will be fine

Could you please solve the problem when there are Chinese characters in the path by modifying configuration files such as php.ini?

欧阳克欧阳克2828 days ago966

reply all(1)I'll reply

  • 世界只因有你

    世界只因有你2017-06-15 09:23:50

    It's not necessary, and the standards don't approve it. The technology comes from abroad, and you should abide by the programming standards.

    reply
    0
  • Cancelreply