Set_include_path difference _php skills under win and Linux

Source: Internet
Author: User
Just the mode of the program, the server on the good program to win under the incredibly wrong.
Later, careful mode was found to be set_include_path problem.
Under win, when you want to include multiple paths, you need to use ";" to separate, but use ":" In Linux.
The Include path setting in Zendframe 2007-06-29 11:55zf in the example of the include_path feeling is not good, will destroy the existing settings, so I feel that this is better to set:

Include Path Setting
Set_include_path (Get_include_path (). Path_separator. __app_root_path__. ' The Library '. Directory_separator. ' ZF '. Directory_separator);

Require ' zend/loader.php ';



Get_include_path () is the current Inc_path path for the system.

__app_root_path__ is a constant that I set for myself, representing the current directory.

Path_separator This can be said, because win under the path is used; (semicolon) to split, but Linux is used: (colon) to split, so use this Changshilai to represent the separator.

This setting is available under Win and Linux.

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.