Parent class for view classes generating serialized outputs like JsonView and XmlView.
string 'templates'
Constant for type used for App::path().
string 'plugin'
Constant for folder name containing files for overriding plugin templates.
string 'element'
Constant for view file type 'element'
string 'layout'
Constant for view file type 'layout'
string '_match_all_'
The magic 'match-all' content type that views can use to behave as a fallback during content-type negotiation.
string 'template'
Constant for view file type 'template'.
Cake\View\ViewBlockCake\View\Helper\BreadcrumbsHelperCake\View\Helper\FlashHelperCake\View\Helper\FormHelperCake\View\Helper\HtmlHelperCake\View\Helper\NumberHelperCake\View\Helper\PaginatorHelperCake\View\Helper\TextHelperCake\View\Helper\TimeHelperCake\View\Helper\UrlHelperarray<string, mixed>Runtime config
boolWhether the config property has already been configured with defaults
stringThe currently rendering view file. Used for resolving parent files.
stringCurrently rendering an element. Used for finding parent fragments for elements.
array<string, mixed>Default config options.
stringDefault class name for new event objects.
Cake\Event\EventManagerInterface|nullInstance of the Cake\Event\EventManager this object is using to dispatch inner events.
stringFile extension. Defaults to ".php".
Cake\View\HelperRegistryHelpers collection
array<string>The names of views and their parents used with View::extend();
array<string>List of variables to collect from the associated controller.
array<string>Holds an array of paths.
array<string[]>Holds an array of plugin paths.
stringResponse type.
array<string>Content stack, used for nested templates that all use View::extend();
stringViewBlock class.
boolTurns on or off CakePHP's conventional mode of applying layout files. On by default. Setting to off means that layouts will not be automatically applied to rendered templates.
stringThe Cache configuration View will use to store cached elements. Changing this will change the default configuration elements are stored under. You can also choose a cache config per element.
arrayAn array of names of built-in helpers to include.
stringThe name of the layout file to render the template inside of. The name specified is the filename of the layout in templates/layout/ without the .php extension.
stringThe name of the layouts subfolder containing layouts for this View.
stringName of the controller that created the View if any.
string|nullThe name of the plugin.
Cake\Http\ServerRequestAn instance of a \Cake\Http\ServerRequest object that contains information about the current request. This object contains all the information about a request and several methods for reading additional information about the request.
Cake\Http\ResponseReference to the Response object
stringSub-directory for this template file. This is often used for extension based routing. Eg. With an xml extension, $subDir would be xml/
stringThe name of the template file to render. The name specified is the filename in templates/<SubFolder>/ without the .php extension.
stringThe name of the subfolder containing templates for this View.
string|nullThe view theme to use.
array<string, mixed>An array of variables
Constructor
Magic accessor for helpers.
Check that a view file path does not go outside of the defined template paths.
Deletes a single config key.
Reads a config key.
Writes a config key.
Create and configure the cell instance.
Generate the cache configuration options for an element.
Sandbox method to evaluate a template / view script in.
Finds an element filename, returns false on failure.
Returns layout filename for this template as a string.
Find all sub templates path, based on $basePath If a prefix is defined in the current request, this method will prepend the prefixed template path to the $basePath, cascading up in case the prefix is nested. This is essentially used to find prefixed template paths for elements and layouts.
Returns filename of given action's template file as a string. CamelCased action names will be under_scored by default. This means that you can have LongActionNames that refer to long_action_names.php templates. You can change the inflection rule by overriding _inflectTemplateFileName.
Change the name of a view template file into underscored format.
Return all possible paths to find view files in order
Renders and returns output for given template filename with its array of data. Handles parent/extended templates.
Renders an element and fires the before and afterRender callbacks for it and writes to the cache if a cache is used
Serialize view vars.
Append to an existing or new block.
Set the content for a block. This will overwrite any existing content.
Get the names of all the existing blocks.
Create a cached block of view logic.
Renders the given cell.
Merge provided config with existing config. Unlike config() which does a recursive merge for nested keys, this method does a simple merge.
Mime-type this view class renders as.
Turns off CakePHP's conventional mode of applying layout files. Layouts will not be automatically applied to rendered views.
Wrapper for creating and dispatching events.
Renders a piece of PHP with provided parameters and returns HTML, XML, or any other string.
Checks if an element exists
Turns on or off CakePHP's conventional mode of applying layout files. On by default. Setting to off means that layouts will not be automatically applied to rendered views.
End a capturing block. The compliment to View::start()
Check if a block exists
Provides template or element extension/inheritance. Templates can extends a parent template and populate blocks in the parent template.
Fetch the content for a block. If a block is empty or undefined '' will be returned.
Returns the contents of the given View variable.
Get config value.
Returns the config for this specific key.
Retrieve the current template type
Get an iterator for element paths.
Returns the Cake\Event\EventManager manager instance for this object.
Get the name of the layout file to render the template inside of. The name specified is the filename of the layout in templates/layout/ without the .php extension.
Get path for layout files.
Get an iterator for layout paths.
Returns the View's controller name.
Returns the plugin name.
Gets the request instance.
Gets the response instance.
Get sub-directory for this template files.
Get the name of the template file to render. The name specified is the filename in templates/<SubFolder>/ without the .php extension.
Get path for templates files.
Get the current view theme.
Returns a list of variables available in the current View context
Get the helper registry in use by this View class.
Initialization hook method.
Returns if CakePHP's conventional mode of applying layout files is enabled. Disabled means that layouts will not be automatically applied to rendered views.
Loads a helper. Delegates to the HelperRegistry::load() to load the helper
Load helpers only if serialization is disabled.
Convenience method to write a message to Log. See Log::write() for more information on writing to logs.
Splits a dot syntax plugin name into its plugin and filename. If $name does not have a dot, then index 0 will be null. It checks if the plugin is loaded, else filename will stay unchanged for filenames containing dot
Prepend to an existing or new block.
Render view template or return serialized data.
Renders a layout. Returns output from _render().
Reset the content for a block. This will overwrite any existing content.
Saves a variable or an associative array of variables for use inside a template.
Sets the config.
Set the response content-type based on the view's contentType()
Set The cache configuration View will use to store cached elements
Returns the Cake\Event\EventManagerInterface instance for this object.
Set the name of the layout file to render the template inside of. The name specified is the filename of the layout in templates/layout/ without the .php extension.
Set path for layout files.
Sets the plugin name.
Sets the request objects and configures a number of controller properties based on the contents of the request. The properties that get set are:
Sets the response instance.
Set sub-directory for this template files.
Set the name of the template file to render. The name specified is the filename in templates/<SubFolder>/ without the .php extension.
Set path for templates files.
Set the view theme to use.
Start capturing output for a 'block'
__construct(Cake\Http\ServerRequest|null $request = null, Cake\Http\Response|null $response = null, Cake\Event\EventManager|null $eventManager = null, array<string, mixed> $viewOptions = [])
Constructor
Cake\Http\ServerRequest|null $request optional Request instance.
Cake\Http\Response|null $response optional Response instance.
Cake\Event\EventManager|null $eventManager optional Event manager instance.
array<string, mixed> $viewOptions optional View options. See {@link View::$_passedVars} for list of options which get set as class properties.
__get(string $name): Cake\View\Helper|null
Magic accessor for helpers.
string $name Name of the attribute to get.
Cake\View\Helper|null_checkFilePath(string $file, string $path): string
Check that a view file path does not go outside of the defined template paths.
Only paths that contain .. will be checked, as they are the ones most likely to have the ability to resolve to files outside of the template paths.
string $file The path to the template file.
string $path Base path that $file should be inside of.
stringInvalidArgumentException_configDelete(string $key): void
Deletes a single config key.
string $key Key to delete.
voidCake\Core\Exception\CakeException_configRead(string|null $key): mixed
Reads a config key.
string|null $key Key to read.
mixed_configWrite(array<string, mixed>|string $key, mixed $value, string|bool $merge = false): void
Writes a config key.
array<string, mixed>|string $key Key to write to.
mixed $value Value to write.
string|bool $merge optional True to merge recursively, 'shallow' for simple merge, false to overwrite, defaults to false.
voidCake\Core\Exception\CakeException_createCell(string $className, string $action, string|null $plugin, array<string, mixed> $options): Cake\View\Cell
Create and configure the cell instance.
string $className The cell classname.
string $action The action name.
string|null $plugin The plugin name.
array<string, mixed> $options The constructor options for the cell.
Cake\View\Cell_elementCache(string $name, array $data, array<string, mixed> $options): array
Generate the cache configuration options for an element.
string $name Element name
array $data Data
array<string, mixed> $options Element options
array_evaluate(string $templateFile, array $dataForView): string
Sandbox method to evaluate a template / view script in.
string $templateFile Filename of the template.
array $dataForView Data to include in rendered view.
string_getElementFileName(string $name, bool $pluginCheck = true): string|false
Finds an element filename, returns false on failure.
string $name The name of the element to find.
bool $pluginCheck optional string|false_getLayoutFileName(string|null $name = null): string
Returns layout filename for this template as a string.
string|null $name optional The name of the layout to find.
stringCake\View\Exception\MissingLayoutExceptionRuntimeException_getSubPaths(string $basePath): array<string>
Find all sub templates path, based on $basePath If a prefix is defined in the current request, this method will prepend the prefixed template path to the $basePath, cascading up in case the prefix is nested. This is essentially used to find prefixed template paths for elements and layouts.
string $basePath Base path on which to get the prefixed one.
array<string>_getTemplateFileName(string|null $name = null): string
Returns filename of given action's template file as a string. CamelCased action names will be under_scored by default. This means that you can have LongActionNames that refer to long_action_names.php templates. You can change the inflection rule by overriding _inflectTemplateFileName.
string|null $name optional Controller action to find template filename for
stringCake\View\Exception\MissingTemplateExceptionRuntimeException_inflectTemplateFileName(string $name): string
Change the name of a view template file into underscored format.
string $name Name of file which should be inflected.
string_paths(string|null $plugin = null, bool $cached = true): array<string>
Return all possible paths to find view files in order
string|null $plugin optional Optional plugin name to scan for view files.
bool $cached optional Set to false to force a refresh of view paths. Default true.
array<string>_render(string $templateFile, array $data = []): string
Renders and returns output for given template filename with its array of data. Handles parent/extended templates.
string $templateFile Filename of the template
array $data optional Data to include in rendered view. If empty the current View::$viewVars will be used.
stringLogicException_renderElement(string $file, array $data, array<string, mixed> $options): string
Renders an element and fires the before and afterRender callbacks for it and writes to the cache if a cache is used
string $file Element file path
array $data Data to render
array<string, mixed> $options Element options
string_serialize(array|string $serialize): string
Serialize view vars.
array|string $serialize The name(s) of the view variable(s) that need(s) to be serialized
stringappend(string $name, mixed $value = null): $this
Append to an existing or new block.
Appending to a new block will create the block.
string $name Name of the block
mixed $value optional The content for the block. Value will be type cast to string.
$thisassign(string $name, mixed $value): $this
Set the content for a block. This will overwrite any existing content.
string $name Name of the block
mixed $value The content for the block. Value will be type cast to string.
$thisblocks(): array<string>
Get the names of all the existing blocks.
array<string>cache(callable $block, array<string, mixed> $options = []): string
Create a cached block of view logic.
This allows you to cache a block of view output into the cache defined in elementCache.
This method will attempt to read the cache first. If the cache is empty, the $block will be run and the output stored.
callable $block The block of code that you want to cache the output of.
array<string, mixed> $options optional The options defining the cache key etc.
stringRuntimeExceptioncell(string $cell, array $data = [], array<string, mixed> $options = []): Cake\View\Cell
Renders the given cell.
Example:
// Taxonomy\View\Cell\TagCloudCell::smallList()
$cell = $this->cell('Taxonomy.TagCloud::smallList', ['limit' => 10]);
// App\View\Cell\TagCloudCell::smallList()
$cell = $this->cell('TagCloud::smallList', ['limit' => 10]); The display action will be used by default when no action is provided:
// Taxonomy\View\Cell\TagCloudCell::display()
$cell = $this->cell('Taxonomy.TagCloud'); Cells are not rendered until they are echoed.
string $cell You must indicate cell name, and optionally a cell action. e.g.: TagCloud::smallList will invoke View\Cell\TagCloudCell::smallList(), display action will be invoked by default when none is provided.
array $data optional Additional arguments for cell method. e.g.: cell('TagCloud::smallList', ['a1' => 'v1', 'a2' => 'v2']) maps to View\Cell\TagCloud::smallList(v1, v2)
array<string, mixed> $options optional Options for Cell's constructor
Cake\View\CellCake\View\Exception\MissingCellExceptionconfigShallow(array<string, mixed>|string $key, mixed|null $value = null): $this
Merge provided config with existing config. Unlike config() which does a recursive merge for nested keys, this method does a simple merge.
Setting a specific value:
$this->configShallow('key', $value); Setting a nested value:
$this->configShallow('some.nested.key', $value); Updating multiple config settings at the same time:
$this->configShallow(['one' => 'value', 'another' => 'value']);
array<string, mixed>|string $key The key to set, or a complete array of configs.
mixed|null $value optional The value to set.
$thiscontentType(): string
Mime-type this view class renders as.
stringdisableAutoLayout(): $this
Turns off CakePHP's conventional mode of applying layout files. Layouts will not be automatically applied to rendered views.
$thisdispatchEvent(string $name, array|null $data = null, object|null $subject = null): Cake\Event\EventInterface
Wrapper for creating and dispatching events.
Returns a dispatched event.
string $name Name of the event.
array|null $data optional Any value you wish to be transported with this event to it can be read by listeners.
object|null $subject optional The object that this event applies to ($this by default).
Cake\Event\EventInterfaceelement(string $name, array $data = [], array<string, mixed> $options = []): string
Renders a piece of PHP with provided parameters and returns HTML, XML, or any other string.
This realizes the concept of Elements, (or "partial layouts") and the $params array is used to send data to be used in the element. Elements can be cached improving performance by using the cache option.
string $name Name of template file in the templates/element/ folder, or MyPlugin.template to use the template element from MyPlugin. If the element is not found in the plugin, the normal view path cascade will be searched.
array $data optional Array of data to be made available to the rendered view (i.e. the Element)
array<string, mixed> $options optional Array of options. Possible keys are:
stringCake\View\Exception\MissingElementExceptionelementExists(string $name): bool
Checks if an element exists
string $name Name of template file in the templates/element/ folder, or MyPlugin.template to check the template element from MyPlugin. If the element is not found in the plugin, the normal view path cascade will be searched.
boolenableAutoLayout(bool $enable = true): $this
Turns on or off CakePHP's conventional mode of applying layout files. On by default. Setting to off means that layouts will not be automatically applied to rendered views.
bool $enable optional Boolean to turn on/off.
$thisend(): $this
End a capturing block. The compliment to View::start()
$thisexists(string $name): bool
Check if a block exists
string $name Name of the block
boolextend(string $name): $this
Provides template or element extension/inheritance. Templates can extends a parent template and populate blocks in the parent template.
string $name The template or element to 'extend' the current one with.
$thisLogicExceptionLogicExceptionfetch(string $name, string $default = ''): string
Fetch the content for a block. If a block is empty or undefined '' will be returned.
string $name Name of the block
string $default optional Default text
stringget(string $var, mixed $default = null): mixed
Returns the contents of the given View variable.
string $var The view var you want the contents of.
mixed $default optional The default/fallback content of $var.
mixedgetConfig(string|null $key = null, mixed $default = null): mixed
Get config value.
Currently if config is not set it fallbacks to checking corresponding view var with underscore prefix. Using underscore prefixed special view vars is deprecated and this fallback will be removed in CakePHP 4.1.0.
string|null $key optional The key to get or null for the whole config.
mixed $default optional The return value when the key does not exist.
mixedgetConfigOrFail(string $key): mixed
Returns the config for this specific key.
The config value for this key must exist, it can never be null.
string $key The key to get.
mixedInvalidArgumentExceptiongetCurrentType(): string
Retrieve the current template type
stringgetElementPaths(string|null $plugin): Generator
Get an iterator for element paths.
string|null $plugin The plugin to fetch paths for.
GeneratorgetEventManager(): Cake\Event\EventManagerInterface
Returns the Cake\Event\EventManager manager instance for this object.
You can use this instance to register any new listeners or callbacks to the object events, or create your own events and trigger them at will.
Cake\Event\EventManagerInterfacegetLayout(): string
Get the name of the layout file to render the template inside of. The name specified is the filename of the layout in templates/layout/ without the .php extension.
stringgetLayoutPath(): string
Get path for layout files.
stringgetLayoutPaths(string|null $plugin): Generator
Get an iterator for layout paths.
string|null $plugin The plugin to fetch paths for.
GeneratorgetName(): string
Returns the View's controller name.
stringgetPlugin(): string|null
Returns the plugin name.
string|nullgetRequest(): Cake\Http\ServerRequest
Gets the request instance.
Cake\Http\ServerRequestgetResponse(): Cake\Http\Response
Gets the response instance.
Cake\Http\ResponsegetSubDir(): string
Get sub-directory for this template files.
stringgetTemplate(): string
Get the name of the template file to render. The name specified is the filename in templates/<SubFolder>/ without the .php extension.
stringgetTemplatePath(): string
Get path for templates files.
stringgetTheme(): string|null
Get the current view theme.
string|nullgetVars(): array<string>
Returns a list of variables available in the current View context
array<string>helpers(): Cake\View\HelperRegistry
Get the helper registry in use by this View class.
Cake\View\HelperRegistryinitialize(): void
Initialization hook method.
Properties like $helpers etc. cannot be initialized statically in your custom view class as they are overwritten by values from controller in constructor. So this method allows you to manipulate them as required after view instance is constructed.
voidisAutoLayoutEnabled(): bool
Returns if CakePHP's conventional mode of applying layout files is enabled. Disabled means that layouts will not be automatically applied to rendered views.
boolloadHelper(string $name, array<string, mixed> $config = []): Cake\View\Helper
Loads a helper. Delegates to the HelperRegistry::load() to load the helper
string $name Name of the helper to load.
array<string, mixed> $config optional Settings for the helper
Cake\View\HelperloadHelpers(): $this
Load helpers only if serialization is disabled.
$thislog(string $message, string|int $level = LogLevel::ERROR, array|string $context = []): bool
Convenience method to write a message to Log. See Log::write() for more information on writing to logs.
string $message Log message.
string|int $level optional Error level.
array|string $context optional Additional log data relevant to this message.
boolpluginSplit(string $name, bool $fallback = true): array
Splits a dot syntax plugin name into its plugin and filename. If $name does not have a dot, then index 0 will be null. It checks if the plugin is loaded, else filename will stay unchanged for filenames containing dot
string $name The name you want to plugin split.
bool $fallback optional If true uses the plugin set in the current Request when parsed plugin is not loaded
arrayprepend(string $name, mixed $value): $this
Prepend to an existing or new block.
Prepending to a new block will create the block.
string $name Name of the block
mixed $value The content for the block. Value will be type cast to string.
$thisrender(string|null $template = null, string|false|null $layout = null): string
Render view template or return serialized data.
Render triggers helper callbacks, which are fired before and after the template are rendered, as well as before and after the layout. The helper callbacks are called:
beforeRenderafterRenderbeforeLayoutafterLayoutIf View::$autoLayout is set to false, the template will be returned bare.
Template and layout names can point to plugin templates or layouts. Using the Plugin.template syntax a plugin template/layout/ can be used instead of the app ones. If the chosen plugin is not found the template will be located along the regular view path cascade.
string|null $template optional The template being rendered.
string|false|null $layout optional The layout being rendered.
stringCake\View\Exception\SerializationFailureExceptionrenderLayout(string $content, string|null $layout = null): string
Renders a layout. Returns output from _render().
Several variables are created for use in layout.
string $content Content to render in a template, wrapped by the surrounding layout.
string|null $layout optional Layout name
stringCake\Core\Exception\CakeExceptionreset(string $name): $this
Reset the content for a block. This will overwrite any existing content.
string $name Name of the block
$thisset(array|string $name, mixed $value = null): $this
Saves a variable or an associative array of variables for use inside a template.
array|string $name A string or an array of data.
mixed $value optional Value in case $name is a string (which then works as the key). Unused if $name is an associative array, otherwise serves as the values to $name's keys.
$thisRuntimeExceptionsetConfig(array<string, mixed>|string $key, mixed|null $value = null, bool $merge = true): $this
Sets the config.
Setting a specific value:
$this->setConfig('key', $value); Setting a nested value:
$this->setConfig('some.nested.key', $value); Updating multiple config settings at the same time:
$this->setConfig(['one' => 'value', 'another' => 'value']);
array<string, mixed>|string $key The key to set, or a complete array of configs.
mixed|null $value optional The value to set.
bool $merge optional Whether to recursively merge or overwrite existing config, defaults to true.
$thisCake\Core\Exception\CakeExceptionsetContentType(): void
Set the response content-type based on the view's contentType()
voidsetElementCache(string $elementCache): $this
Set The cache configuration View will use to store cached elements
string $elementCache Cache config name.
$thissetEventManager(Cake\Event\EventManagerInterface $eventManager): $this
Returns the Cake\Event\EventManagerInterface instance for this object.
You can use this instance to register any new listeners or callbacks to the object events, or create your own events and trigger them at will.
Cake\Event\EventManagerInterface $eventManager the eventManager to set
$thissetLayout(string $name): $this
Set the name of the layout file to render the template inside of. The name specified is the filename of the layout in templates/layout/ without the .php extension.
string $name Layout file name to set.
$thissetLayoutPath(string $path): $this
Set path for layout files.
string $path Path for layout files.
$thissetPlugin(string|null $name): $this
Sets the plugin name.
string|null $name Plugin name.
$thissetRequest(Cake\Http\ServerRequest $request): $this
Sets the request objects and configures a number of controller properties based on the contents of the request. The properties that get set are:
Cake\Http\ServerRequest $request Request instance.
$thissetResponse(Cake\Http\Response $response): $this
Sets the response instance.
Cake\Http\Response $response Response instance.
$thissetSubDir(string $subDir): $this
Set sub-directory for this template files.
string $subDir Sub-directory name.
$thissetTemplate(string $name): $this
Set the name of the template file to render. The name specified is the filename in templates/<SubFolder>/ without the .php extension.
string $name Template file name to set.
$thissetTemplatePath(string $path): $this
Set path for templates files.
string $path Path for template files.
$thissetTheme(string|null $theme): $this
Set the view theme to use.
string|null $theme Theme name.
$thisstart(string $name): $this
Start capturing output for a 'block'
You can use start on a block multiple times to append or prepend content in a capture mode.
// Append content to an existing block.
$this->start('content');
echo $this->fetch('content');
echo 'Some new content';
$this->end();
// Prepend content to an existing block
$this->start('content');
echo 'Some new content';
echo $this->fetch('content');
$this->end(); string $name The name of the block to capture for.
$thisCake\View\ViewBlockCake\View\Helper\BreadcrumbsHelperCake\View\Helper\FlashHelperCake\View\Helper\FormHelperCake\View\Helper\HtmlHelperCake\View\Helper\NumberHelperCake\View\Helper\PaginatorHelperCake\View\Helper\TextHelperCake\View\Helper\TimeHelperCake\View\Helper\UrlHelperRuntime config
array<string, mixed>Whether the config property has already been configured with defaults
boolThe currently rendering view file. Used for resolving parent files.
stringCurrently rendering an element. Used for finding parent fragments for elements.
stringDefault config options.
Use ViewBuilder::setOption()/setOptions() in your controlle to set these options.
serialize: Option to convert a set of view variables into a serialized response. Its value can be a string for single variable name or array for multiple names. If true all view variables will be serialized. If null or false normal view template will be rendered.array<string, mixed>Default class name for new event objects.
stringInstance of the Cake\Event\EventManager this object is using to dispatch inner events.
Cake\Event\EventManagerInterface|nullFile extension. Defaults to ".php".
stringHelpers collection
Cake\View\HelperRegistryThe names of views and their parents used with View::extend();
array<string>List of variables to collect from the associated controller.
array<string>Holds an array of paths.
array<string>Holds an array of plugin paths.
array<string[]>Response type.
stringContent stack, used for nested templates that all use View::extend();
array<string>ViewBlock class.
stringTurns on or off CakePHP's conventional mode of applying layout files. On by default. Setting to off means that layouts will not be automatically applied to rendered templates.
boolThe Cache configuration View will use to store cached elements. Changing this will change the default configuration elements are stored under. You can also choose a cache config per element.
stringAn array of names of built-in helpers to include.
arrayThe name of the layout file to render the template inside of. The name specified is the filename of the layout in templates/layout/ without the .php extension.
stringThe name of the layouts subfolder containing layouts for this View.
stringName of the controller that created the View if any.
stringThe name of the plugin.
string|nullAn instance of a \Cake\Http\ServerRequest object that contains information about the current request. This object contains all the information about a request and several methods for reading additional information about the request.
Cake\Http\ServerRequestReference to the Response object
Cake\Http\ResponseSub-directory for this template file. This is often used for extension based routing. Eg. With an xml extension, $subDir would be xml/
stringThe name of the template file to render. The name specified is the filename in templates/<SubFolder>/ without the .php extension.
stringThe name of the subfolder containing templates for this View.
stringThe view theme to use.
string|nullAn array of variables
array<string, mixed>
© 2005–present The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
https://api.cakephp.org/4.4/class-Cake.View.SerializedView.html