Application execution order

From Joomla! Documentation
(Difference between revisions)
Jump to: navigation, search
m (moved API Execution Order to Application execution order: Adjusted title to be more specific)
 
(One intermediate revision by one user not shown)
Line 73: Line 73:
  
 
TODO
 
TODO
 +
 +
[[Category:Framework]][[Category:References]]

Latest revision as of 17:30, 15 July 2012

Note

Please note that the content on this page is currently incomplete. Please treat it as a work in progress.

This article was last edited by Mvangeest (talk| contribs) 10 months ago. (Purge)

Contents

[edit] Typical Frontend Application Execution

This section outlines key points in the execution of the Joomla! script including, but not limited to, key files that are includes, key methods that are called, trigger, and so on.

[edit] Initialisation

  • Load once: defines.php
  • Load once: framework.php
    • Modify configuration options for magic quotes and Zend compatibility
    • Check for configuration.php. Redirect to installation if present or halt.
    • Load once: import.php
    • Load once: configuration.php
    • Set error reporting
    • Load PHP compatibility functions and classes
    • Initialise profiler (if debug on)
    • Import joomla.application.menu
    • Import joomla.user.user
    • Import joomla.environment.uri
    • Import joomla.html.html
    • Import joomla.utilities.utility
    • Import joomla.event.event
    • Import joomla.event.dispatcher
    • Import joomla.language.language
    • Import joomla.utilities.string
  • Profile mark: afterLoad
  • Set global $mainframe. Call to JFactory::getApplication('site')
    • Create and return instance. Call to JApplication::getInstance
  • Initialise the application. Call to JSite::initialise
    • Load base language files
    • Call to parent::initialise
      • First call to JFactory::getUser (initialises user)
        • Import joomla.user.user
        • Create session. Call to JFactory::getSession
      • Set editor based on user preference if available
  • Import the system plugins. Call to JPluginHelper::importPlugin('system')
  • Profile mark: afterInitialise
  • Trigger events: onAfterInitialise

[edit] Routing and Authorisation

  • Route the URI: Call to JSite::route
  • Call to JSite::authorize
    • Check current menu item access level. Redirect if not logged in. Halt if logged in and not authorised.
  • Profile mark: afterRoute
  • Trigger events: onAfterRoute

[edit] Dispatching

  • Dispatch the component: Call to JSite::dispatch
  • Profile mark: afterDispatch
  • Trigger events: onAfterDispatch

[edit] Rendering

  • Render the page: Call to JSite::render
  • Profile mark: afterRender
  • Trigger events: onAfterRender
  • Echo output: Call to JResponse::toString with option for compressed output

[edit] Typical Administrator Application Execution

TODO

[edit] Typical XML-RPC Application Execution

TODO

[edit] Login Event Execution

This execution trace begins with at the User Component Controller method for login, UserController::login (called within the application dispatch method)

TODO

Personal tools
Namespaces

Variants
Actions
Navigation
Joomla! Sites
Toolbox