|
|
Subscribe / Log in / New account

PHP and P++

PHP and P++

Posted Aug 15, 2019 22:09 UTC (Thu) by roc (subscriber, #30627)
In reply to: PHP and P++ by rweikusat2
Parent article: PHP and P++

Treating everything as bytes is fine for filesystem APIs, but a big problem arises when you want to print path names; if you don't know the encoding, and the path name is not ASCII, you can't print them correctly. A slightly lesser problem is the reverse: when you receive a path name that happens to be in Unicode (because it comes from user input in Unicode, for example), and is non-ASCII.

If you care about those problems then you need to define the encoding of path names, and decide how to handle path names that aren't valid in the encoding.


to post comments


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds