From 0f332e6564ed67ef7eb4d715ce3bcb5ff54c50cf Mon Sep 17 00:00:00 2001 From: Ciro Mattia Gonano Date: Wed, 24 Jul 2013 12:22:49 +0200 Subject: Upgrade to newly released 3.2.2 --- .../protected/pages/Configurations/AppConfig.page | 57 ++++++++++++++++++++++ .../pages/Controls/ClientScriptLoader.page | 0 .../pages/GettingStarted/NewFeatures.page | 14 ++++-- 3 files changed, 68 insertions(+), 3 deletions(-) delete mode 100644 demos/quickstart/protected/pages/Controls/ClientScriptLoader.page (limited to 'demos/quickstart/protected') diff --git a/demos/quickstart/protected/pages/Configurations/AppConfig.page b/demos/quickstart/protected/pages/Configurations/AppConfig.page index 83f1bc7e..7887d959 100644 --- a/demos/quickstart/protected/pages/Configurations/AppConfig.page +++ b/demos/quickstart/protected/pages/Configurations/AppConfig.page @@ -56,4 +56,61 @@ An external configuration file has the same format as described above. Although By default without explicit configuration, a PRADO application will load a few core modules, such as THttpRequest, THttpResponse, etc. It will also provide the TPageService as a default service. Configuration and usage of these modules and services are covered in individual sections of this tutorial. Note, if your application takes default settings for these modules and service, you do not need to provide an application configuration. However, if these modules or services are not sufficient, or you want to change their behavior by configuring their property values, you will need an application configuration.

+ +

+By default PRADO instanciates all modules defined in the application configuration at the beginning of the application lifecycle. This can hit the application performance if you have a lot of modules defined but not used at every request. +Since version 3.2.2 you can set the lazy property on modules defined in the application configuration to enable the lazy loading of that module. + + + + + + + +A module with the lazy property set won't be instanciated until the first time it gets actually used by the application: + + + // requesting the lazy module to the application will instanciate it + Prado::getApplication()->getModule('ModuleID'); + +

+ + +

+Since version 3.2 the application configuration can be stored in PHP array format in a file named application.php. +The format of the configuration file is exactly the same of its XML counterpart, but following the PHP syntax. +

+ + + array( + 'PropertyName' => 'PropertyValue' + ), + 'modules' => array( + 'ModuleID' => array( + 'class' => 'ModuleClass', + 'properties' => array( + 'PropertyName' => 'PropertyValue' + ), + ), + ), + 'services' => array( + 'ServiceID' => array( + 'class' => 'ServiceClass', + 'properties' => array( + 'PropertyName' => 'PropertyValue' + ), + ), + ), +); + + +The use of a PHP application configuration must be defined in the TApplication constructor, tipically located in the index.php entry script: + + +$application=new TApplication('protected',false,TApplication::CONFIG_TYPE_PHP); +$application->run(); + + diff --git a/demos/quickstart/protected/pages/Controls/ClientScriptLoader.page b/demos/quickstart/protected/pages/Controls/ClientScriptLoader.page deleted file mode 100644 index e69de29b..00000000 diff --git a/demos/quickstart/protected/pages/GettingStarted/NewFeatures.page b/demos/quickstart/protected/pages/GettingStarted/NewFeatures.page index 98adc925..aaeb2b9c 100644 --- a/demos/quickstart/protected/pages/GettingStarted/NewFeatures.page +++ b/demos/quickstart/protected/pages/GettingStarted/NewFeatures.page @@ -6,11 +6,19 @@ This page summarizes the main new features that are introduced in each PRADO release.

+

Version 3.2.2

+
    +
  • TUrlMappingPattern support for constant parameters
  • +
  • Added EnableCache property to THttpRequest to enable caching of the TUrlManager and any TMappingUrl pattern
  • +
  • Lazy module loading in application configuration
  • +
  • TEACache eAccellerator cache module
  • +
+

Version 3.2.1

    -
  • TSecurityManager has been enhanced to support all the ciphers available in php
  • -
  • Added a new UrlFormat for TUrlManager: HiddenPath; works like the 'Path' format, but hides the entryscript.php name
  • -
  • Updated external packages
  • +
  • TSecurityManager has been enhanced to support all the ciphers available in php
  • +
  • Added a new UrlFormat for TUrlManager: HiddenPath; works like the 'Path' format, but hides the entryscript.php name
  • +
  • Updated external packages

Version 3.2.0

-- cgit v1.2.3