From 6ea993425cc0982ecef765d4bfc6b75b7206416d Mon Sep 17 00:00:00 2001 From: xue <> Date: Wed, 28 Dec 2005 13:11:07 +0000 Subject: --- .../protected/pages/Fundamentals/Applications.page | 28 +++++++++++----------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'demos/quickstart/protected/pages/Fundamentals/Applications.page') diff --git a/demos/quickstart/protected/pages/Fundamentals/Applications.page b/demos/quickstart/protected/pages/Fundamentals/Applications.page index c64a9ea4..8ea9a1f7 100644 --- a/demos/quickstart/protected/pages/Fundamentals/Applications.page +++ b/demos/quickstart/protected/pages/Fundamentals/Applications.page @@ -2,7 +2,7 @@

Applications

-An application is an instance of TApplication or its derived class. It manages modules that provide different functionalities and are loaded when needed. It provides services to end-users. It is the central place to store various parameters used in an application. In a PRADO application, the application instance is the only object that is globally accessible via Prado::getApplication() function call. +An application is an instance of TApplication or its derived class. It manages modules that provide different functionalities and are loaded when needed. It provides services to end-users. It is the central place to store various parameters used in an application. In a PRADO application, the application instance is the only object that is globally accessible via Prado::getApplication() function call.

Applications are configured via application configurations. They are usually created entry scripts like the following, @@ -11,7 +11,7 @@ require_once('/path/to/prado.php'); $application = new TApplication; $application->run(); -where the method run() starts the application to handle user requests. +where the method run() starts the application to handle user requests.

Directory Organization

@@ -19,32 +19,32 @@ where the method run() starts the application to handle user reques A minimal PRADO application contains two files: an entry file and a page template file. They must be organized as follows,

-A product PRADO application usually needs more files. It may include an application configuration file named application.xml under the application base path protected. The pages may be organized in directories, some of which may contain page configuration files named config.xml. Fore more details, please see configurations section. +A product PRADO application usually needs more files. It may include an application configuration file named application.xml under the application base path protected. The pages may be organized in directories, some of which may contain page configuration files named config.xml. Fore more details, please see configurations section.

Application Deployment

Deploying a PRADO application mainly involves copying directories. For example, to deploy the above minimal application to another server, follow the following steps,

    -
  1. Copy the content under wwwroot to a Web-accessible directory on the new server.
  2. -
  3. Modify the entry script file index.php so that it includes correctly the prado.php file.
  4. -
  5. Remove all content under assets and runtime directories and make sure both directories are writable by the Web server process.
  6. +
  7. Copy the content under wwwroot to a Web-accessible directory on the new server.
  8. +
  9. Modify the entry script file index.php so that it includes correctly the prado.php file.
  10. +
  11. Remove all content under assets and runtime directories and make sure both directories are writable by the Web server process.

Application Lifecycles

-Like page lifecycles, an application also has lifecycles. Application modules can register for the lifecycle events. When the application reaches a particular lifecycle and raises the corresponding event, the registered module methods are invoked automatically. Modules included in the PRADO release, such as TAuthManager, are using this way to accomplish their goals. +Like page lifecycles, an application also has lifecycles. Application modules can register for the lifecycle events. When the application reaches a particular lifecycle and raises the corresponding event, the registered module methods are invoked automatically. Modules included in the PRADO release, such as TAuthManager, are using this way to accomplish their goals.

The application lifecycles can be depicted as follows, -- cgit v1.2.3