Skip to content
This repository was archived by the owner on Jan 31, 2020. It is now read-only.

Commit 9a5152b

Browse files
committed
Hotfix: use short array notation in the documentation
1 parent 5a8aaf4 commit 9a5152b

File tree

5 files changed

+8
-8
lines changed

5 files changed

+8
-8
lines changed

docs/book/helpers/cycle.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ The output of the two previous examples combined becomes:
6464

6565
If you are nesting cycles, you must provide all but one of them with a name; do
6666
this by providing a second parameter to the `cycle()` invocation:
67-
`$this->cycle(array('odd', 'even'), 'cycle2')`
67+
`$this->cycle(['odd', 'even'], 'cycle2')`
6868

6969
```php
7070
<table>

docs/book/helpers/flash-messenger.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -105,10 +105,10 @@ $flash->setMessageOpenFormat('<div%s>
105105
->setMessageSeparatorString('</li><li>')
106106
->setMessageCloseString('</li></ul></div>');
107107

108-
echo $flash->render('error', array('alert', 'alert-dismissible', 'alert-danger'));
109-
echo $flash->render('info', array('alert', 'alert-dismissible', 'alert-info'));
110-
echo $flash->render('default', array('alert', 'alert-dismissible', 'alert-warning'));
111-
echo $flash->render('success', array('alert', 'alert-dismissible', 'alert-success'));
108+
echo $flash->render('error', ['alert', 'alert-dismissible', 'alert-danger']);
109+
echo $flash->render('info', ['alert', 'alert-dismissible', 'alert-info']);
110+
echo $flash->render('default', ['alert', 'alert-dismissible', 'alert-warning']);
111+
echo $flash->render('success', ['alert', 'alert-dismissible', 'alert-success']);
112112
```
113113

114114
The output of the above example would create dismissable `FlashMessages` with

docs/book/helpers/head-meta.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ optional associative array that can contain keys for `lang` and/or `scheme`.
4444

4545
You may also set meta tags using the `headMeta()` helper method, which has the
4646
following signature: `headMeta($content, $keyValue, $keyType = 'name',
47-
$modifiers = array(), $placement = 'APPEND')`. `$keyValue` is the content for
47+
$modifiers = [], $placement = 'APPEND')`. `$keyValue` is the content for
4848
the key specified in `$keyType`, which should be either `name` or `http-equiv`.
4949
`$keyType` may also be specified as `property` if the doctype has been set to
5050
`XHTML1_RDFA`. `$placement` can be `SET` (overwrites all previously stored

docs/book/helpers/head-style.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ The usage for this will be showed in an example below.
3939
4040
Finally, you can also use the `headStyle()` method to quickly add declarations
4141
elements; the signature for this is `headStyle($content = null, $placement =
42-
'APPEND', $attributes = array())`. `$placement` should be either `APPEND`,
42+
'APPEND', $attributes = [])`. `$placement` should be either `APPEND`,
4343
`PREPEND`, or `SET`.
4444
4545
`HeadStyle` overrides each of `append()`, `offsetSet()`, `prepend()`, and

docs/book/php-renderer.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ inject some variables. This can be done in 4 different ways.
109109

110110
- Pass an associative array (or `ArrayAccess` instance, or `Zend\View\Variables`
111111
instance) of items as the second argument to `render()`:
112-
`$renderer->render($templateName, array('foo' =&gt; 'bar))`
112+
`$renderer->render($templateName, ['foo' => 'bar'])`
113113
- Assign a `Zend\View\Variables` instance, associative array, or `ArrayAccess`
114114
instance to the `setVars()` method.
115115
- Assign variables as instance properties of the renderer: `$renderer->foo =

0 commit comments

Comments
 (0)