View Single Post
  #10  
Old 5th November 2009, 18:13
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 35,717
Thanks: 820
Thanked 5,322 Times in 4,175 Posts
Default

The $app object is initialized when the framework is loaded, so no need to initialize it. Using it globally is just a line of code of nearly the same length then loading it in every function. All classes are availble as $app->classname->function(), so code is very easy to navigate.

Quote:
One have no idea what global $app/$config is
Everyone developing in ispconfig and looked at the code before knows it as its the basic principle of this software. ISPConfig requires a coding style and the decision to use a global $app and $config object is one of the coding standards of this project.

The ispconfig classes are not made and its not intended to use them in other external applications. They are just written to work as part of the ispconfig framework.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote