A AclBase AclBehavior AclComponent AclNode AclShell Aco AcoAction AjaxHelper ApcEngine ApiShell App AppController AppController AppHelper AppHelper AppModel AppModel Aro AuthComponent B BakeShell BakeTask BehaviorCollection C Cache CacheEngine CacheHelper CakeErrorController CakeLog CakeRoute CakeSchema CakeSession CakeSocket ClassRegistry Component Configure ConnectionManager ConsoleShell ContainableBehavior Controller ControllerTask CookieComponent D DataSource DbAcl DbAclSchema DbConfigTask DboMssql DboMysql DboMysqlBase DboMysqli DboOracle DboPostgres DboSource DboSqlite Debugger Dispatcher E EmailComponent ErrorHandler ErrorHandler ExtractTask F File FileEngine FileLog FixtureTask Folder FormHelper H Helper HtmlHelper HttpSocket I I18n I18nModel i18nSchema I18nShell Inflector IniAcl J JavascriptHelper JqueryEngineHelper JsBaseEngineHelper JsHelper L L10n M MagicDb MagicFileResource MediaView MemcacheEngine Model ModelBehavior ModelTask MootoolsEngineHelper Multibyte N NumberHelper O Object Overloadable Overloadable Overloadable2 Overloadable2 P PagesController PagesController PaginatorHelper Permission PluginShortRoute PluginTask ProjectTask PrototypeEngineHelper R RequestHandlerComponent Router RssHelper S Sanitize Scaffold ScaffoldView SchemaShell Security SecurityComponent SessionComponent SessionHelper SessionsSchema Set Shell ShellDispatcher String T TemplateTask TestSuiteShell TestTask TextHelper ThemeView TimeHelper TranslateBehavior TreeBehavior V Validation View ViewTask X XcacheEngine Xml XmlElement XmlHelper XmlManager XmlNode XmlTextNode

startup

line:229 at /cake/libs/controller/components/request_handler.php
The startup method of the RequestHandler enables several automatic behaviors related to the detection of certain properties of the HTTP request, including:

Method

(void) startup (&$controller)

Parameters

ParameterTypeCommentDefault
$controller object required A reference to the controller

Return

void

Comment

The startup method of the RequestHandler enables several automatic behaviors
related to the detection of certain properties of the HTTP request, including:

- Disabling layout rendering for Ajax requests (based on the HTTP_X_REQUESTED_WITH header)
- If Router::parseExtensions() is enabled, the layout and template type are
switched based on the parsed extension. For example, if controller/action.xml
is requested, the view path becomes <i>app/views/controller/xml/action.ctp</i>.
- If a helper with the same name as the extension exists, it is added to the controller.
- If the extension is of a type that RequestHandler understands, it will set that
Content-type in the response header.
- If the XML data is POSTed, the data is parsed into an XML object, which is assigned
to the $data property of the controller, which can then be saved to a model object.

@param object $controller A reference to the controller
@return void
@access public