Skip to content
Permalink
Browse files

Clarify string type casting of view block values.

Refs #8921
  • Loading branch information...
ADmad committed Jun 1, 2016
1 parent d49cddf commit 1fbcce50d70599f751867842368da42f4078b2af
Showing with 11 additions and 6 deletions.
  1. +7 −4 src/View/View.php
  2. +4 −2 src/View/ViewBlock.php
@@ -707,7 +707,8 @@ public function start($name)
* Appending to a new block will create the block.
*
* @param string $name Name of the block
* @param mixed $value The content for the block.
* @param mixed $value The content for the block. Value will be type cast
* to string.
* @return void
* @see \Cake\View\ViewBlock::concat()
*/
@@ -722,7 +723,8 @@ public function append($name, $value = null)
* Prepending to a new block will create the block.
*
* @param string $name Name of the block
* @param mixed $value The content for the block.
* @param mixed $value The content for the block. Value will be type cast
* to string.
* @return void
* @see \Cake\View\ViewBlock::concat()
*/
@@ -736,7 +738,8 @@ public function prepend($name, $value)
* existing content.
*
* @param string $name Name of the block
* @param mixed $value The content for the block.
* @param mixed $value The content for the block. Value will be type cast
* to string.
* @return void
* @see \Cake\View\ViewBlock::set()
*/
@@ -764,7 +767,7 @@ public function reset($name)
*
* @param string $name Name of the block
* @param string $default Default text
* @return string default The block content or $default if the block does not exist.
* @return string The block content or $default if the block does not exist.
* @see \Cake\View\ViewBlock::get()
*/
public function fetch($name, $default = '')
@@ -129,7 +129,8 @@ public function end()
* of the new capturing context will be added to the existing block context.
*
* @param string $name Name of the block
* @param mixed $value The content for the block
* @param mixed $value The content for the block. Value will be type cast
* to string.
* @param string $mode If ViewBlock::APPEND content will be appended to existing content.
* If ViewBlock::PREPEND it will be prepended.
* @return void
@@ -156,7 +157,8 @@ public function concat($name, $value = null, $mode = ViewBlock::APPEND)
* existing content.
*
* @param string $name Name of the block
* @param mixed $value The content for the block.
* @param mixed $value The content for the block. Value will be type cast
* to string.
* @return void
*/
public function set($name, $value)

0 comments on commit 1fbcce5

Please sign in to comment.
You can’t perform that action at this time.