Windows and linux are separated. you will find some nuances in the video, such as the Com class defined in linux, but it cannot be used after it is transplanted to windows, the video below describes the development of yafphp in windows. windows and linux are explained separately. you will find some nuances in the video, such as the Com class I defined in linux, however, it cannot be used after it is transplanted to windows. the following video describes the development of yaf php in windows!
Like linux, you also need to configure php. ini and app. ini.
// Php. ini
Yaf. library = "your global class loading path"
App. ini
Application. library = "local class loading Directory"
(2) pay attention to loading classes
// Loading method of official documents is not available
$ Loader = Yaf_Loader: Instance ();
$ Loader-> registerLocalNamespace (array ("Foo", "Local "));
// This is feasible below
$ Loader = Yaf_Loader: getInstance ();
$ Loader-> registerLocalNamespace (array ("Foo", "Local "));
Thanks for the code, and leave a message if you don't understand it.
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.