Is directoryseparator in PHP unnecessary?

Source: Internet
Author: User
Is it unnecessary to use directoryseparator when Windows and * unix systems are accepted for unified use? refer to the two articles about unnecessary: alanhogan. comtipsphp... us2.php. netmanualen... check whether it is necessary... windows accept // and \
* Accepted by the unix system/

Unified use/is it unnecessary to use directory separator?

For more information, see the following:

Http://alanhogan.com/tips/php...

Http://us2.php.net/manual/en...

Are you sure you don't need it?

Reply content:

Windows accept // and \
* Accepted by the unix system/

Unified use/is it unnecessary to use directory separator?

For more information, see the following:

Http://alanhogan.com/tips/php...

Http://us2.php.net/manual/en...

Are you sure you don't need it?

I have encountered a uniform path. I have not found any problems.

I don't think it is necessary.PHP_EOLIt is still useful. I don't know how to define each projectDS..
There is a reason that sounds quite reasonable: this is a good habit of code, just like writing when short tag is enabled. Same.

At the end of the first article you gave, this DS is required when you need to use the explode function to separate paths.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.