Skip to content

Commit

Permalink
Update helper usage to 2.x style in code examples
Browse files Browse the repository at this point in the history
  • Loading branch information
ADmad committed Jan 19, 2013
1 parent 631da2d commit db81276
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/Cake/View/Helper/HtmlHelper.php
Expand Up @@ -557,7 +557,7 @@ public function script($url, $options = array()) {
public function scriptBlock($script, $options = array()) {
$options += array('safe' => true, 'inline' => true);
if ($options['safe']) {
$script = "\n" . '//<![CDATA[' . "\n" . $script . "\n" . '//]]>' . "\n";
$script = "\n" . '//<![CDATA[' . "\n" . $script . "\n" . '//]]>' . "\n";
}
if (!$options['inline'] && empty($options['block'])) {
$options['block'] = 'script';
Expand Down Expand Up @@ -616,7 +616,7 @@ public function scriptEnd() {
* ### Usage:
*
* {{{
* echo $html->style(array('margin' => '10px', 'padding' => '10px'), true);
* echo $this->Html->style(array('margin' => '10px', 'padding' => '10px'), true);
*
* // creates
* 'margin:10px;padding:10px;'
Expand Down Expand Up @@ -745,11 +745,11 @@ protected function _prepareCrumbs($startText) {
*
* Create a regular image:
*
* `echo $html->image('cake_icon.png', array('alt' => 'CakePHP'));`
* `echo $this->Html->image('cake_icon.png', array('alt' => 'CakePHP'));`
*
* Create an image link:
*
* `echo $html->image('cake_icon.png', array('alt' => 'CakePHP', 'url' => 'http://cakephp.org'));`
* `echo $this->Html->image('cake_icon.png', array('alt' => 'CakePHP', 'url' => 'http://cakephp.org'));`
*
* ### Options:
*
Expand Down

0 comments on commit db81276

Please sign in to comment.