Skip to content

Commit 4a4a648

Browse files
committed
Merge remote-tracking branch 'upstream/develop' into 4.6
2 parents 31e8f9f + 39c2898 commit 4a4a648

File tree

3 files changed

+32
-23
lines changed

3 files changed

+32
-23
lines changed

system/Database/BaseConnection.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -788,9 +788,9 @@ public function transStart(bool $testMode = false): bool
788788
*
789789
* @return $this
790790
*/
791-
public function transException(bool $transExcetion)
791+
public function transException(bool $transException)
792792
{
793-
$this->transException = $transExcetion;
793+
$this->transException = $transException;
794794

795795
return $this;
796796
}

system/Helpers/html_helper.php

+20-10
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,10 @@
2121
/**
2222
* Unordered List
2323
*
24-
* Generates an HTML unordered list from an single or
25-
* multi-dimensional array.
24+
* Generates an HTML unordered list from a single or
25+
* multidimensional array.
2626
*
27+
* @param array $list List entries
2728
* @param array|object|string $attributes HTML attributes string, array, object
2829
*/
2930
function ul(array $list, $attributes = ''): string
@@ -36,8 +37,9 @@ function ul(array $list, $attributes = ''): string
3637
/**
3738
* Ordered List
3839
*
39-
* Generates an HTML ordered list from an single or multi-dimensional array.
40+
* Generates an HTML ordered list from a single or multidimensional array.
4041
*
42+
* @param array $list List entries
4143
* @param array|object|string $attributes HTML attributes string, array, object
4244
*/
4345
function ol(array $list, $attributes = ''): string
@@ -50,10 +52,10 @@ function ol(array $list, $attributes = ''): string
5052
/**
5153
* Generates the list
5254
*
53-
* Generates an HTML ordered list from an single or multi-dimensional array.
55+
* Generates an HTML ordered list from a single or multidimensional array.
5456
*
55-
* @param array $list
56-
* @param array|object|string $attributes string, array, object
57+
* @param array $list List entries
58+
* @param array|object|string $attributes HTML attributes string, array, object
5759
*/
5860
function _list(string $type = 'ul', $list = [], $attributes = '', int $depth = 0): string
5961
{
@@ -92,7 +94,7 @@ function _list(string $type = 'ul', $list = [], $attributes = '', int $depth = 0
9294
* Generates an image element
9395
*
9496
* @param array|string $src Image source URI, or array of attributes and values
95-
* @param bool $indexPage Whether to treat $src as a routed URI string
97+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the source path
9698
* @param array|object|string $attributes Additional HTML attributes
9799
*/
98100
function img($src = '', bool $indexPage = false, $attributes = ''): string
@@ -192,7 +194,7 @@ function doctype(string $type = 'html5'): string
192194
* Generates link to a JS file
193195
*
194196
* @param array|string $src Script source or an array of attributes
195-
* @param bool $indexPage Should indexPage be added to the JS path
197+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the JS path
196198
*/
197199
function script_tag($src = '', bool $indexPage = false): string
198200
{
@@ -227,7 +229,7 @@ function script_tag($src = '', bool $indexPage = false): string
227229
* Generates link tag
228230
*
229231
* @param array<string, bool|string>|string $href Stylesheet href or an array
230-
* @param bool $indexPage should indexPage be added to the CSS path.
232+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the CSS path.
231233
*/
232234
function link_tag(
233235
$href = '',
@@ -288,6 +290,7 @@ function link_tag(
288290
* @param array|string $src Either a source string or an array of sources
289291
* @param string $unsupportedMessage The message to display if the media tag is not supported by the browser
290292
* @param string $attributes HTML attributes
293+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the source path
291294
*/
292295
function video($src, string $unsupportedMessage = '', string $attributes = '', array $tracks = [], bool $indexPage = false): string
293296
{
@@ -334,6 +337,7 @@ function video($src, string $unsupportedMessage = '', string $attributes = '', a
334337
* @param array|string $src Either a source string or an array of sources
335338
* @param string $unsupportedMessage The message to display if the media tag is not supported by the browser.
336339
* @param string $attributes HTML attributes
340+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the source path
337341
*/
338342
function audio($src, string $unsupportedMessage = '', string $attributes = '', array $tracks = [], bool $indexPage = false): string
339343
{
@@ -413,6 +417,7 @@ function _media(string $name, array $types = [], string $unsupportedMessage = ''
413417
* @param string $src The path of the media resource
414418
* @param string $type The MIME-type of the resource with optional codecs parameters
415419
* @param string $attributes HTML attributes
420+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the source path
416421
*/
417422
function source(string $src, string $type = 'unknown', string $attributes = '', bool $indexPage = false): string
418423
{
@@ -438,7 +443,10 @@ function source(string $src, string $type = 'unknown', string $attributes = '',
438443
* Generates a track element to specify timed tracks. The tracks are
439444
* formatted in WebVTT format.
440445
*
441-
* @param string $src The path of the .VTT file
446+
* @param string $src The path of the .VTT file
447+
* @param string $kind How the text track is meant to be used
448+
* @param string $srcLanguage Language of the track text data
449+
* @param string $label A user-readable title of the text track
442450
*/
443451
function track(string $src, string $kind, string $srcLanguage, string $label): string
444452
{
@@ -461,6 +469,7 @@ function track(string $src, string $kind, string $srcLanguage, string $label): s
461469
* @param string $data A resource URL
462470
* @param string $type Content-type of the resource
463471
* @param string $attributes HTML attributes
472+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the data path
464473
*/
465474
function object(string $data, string $type = 'unknown', string $attributes = '', array $params = [], bool $indexPage = false): string
466475
{
@@ -513,6 +522,7 @@ function param(string $name, string $value, string $type = 'ref', string $attrib
513522
* @param string $src The path of the resource to embed
514523
* @param string $type MIME-type
515524
* @param string $attributes HTML attributes
525+
* @param bool $indexPage Should `Config\App::$indexPage` be added to the source path
516526
*/
517527
function embed(string $src, string $type = 'unknown', string $attributes = '', bool $indexPage = false): string
518528
{

user_guide_src/source/helpers/html_helper.rst

+10-11
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,15 @@ The following functions are available:
3838

3939
.. literalinclude:: html_helper/002.php
4040

41-
There is an optional second parameter that is a true/false value that
42-
specifics if the *src* should have the page specified by
43-
``$config['indexPage']`` added to the address it creates.
41+
There is an optional second parameter, a true/false value, that
42+
specifies if the *src* should have ``Config\App::$indexPage`` added to the address it creates.
4443
Presumably, this would be if you were using a media controller:
4544

4645
.. literalinclude:: html_helper/003.php
4746

4847
Additionally, an associative array can be passed as the first parameter,
4948
for complete control over all attributes and values. If an *alt* attribute
50-
is not provided, CodeIgniter will generate an empty string.
49+
is not provided, CodeIgniter will generate one with empty string.
5150

5251
Example:
5352

@@ -220,8 +219,8 @@ The following functions are available:
220219
:returns: An HTML video element
221220
:rtype: string
222221

223-
Permits you to generate HTML video element from simple or
224-
source arrays. Example:
222+
Permits you to generate an HTML video element from a source string or an array of sources.
223+
Example:
225224

226225
.. literalinclude:: html_helper/014.php
227226

@@ -269,8 +268,8 @@ The following functions are available:
269268
:returns: An HTML source element
270269
:rtype: string
271270

272-
Lets you create HTML ``<source>`` elements. The first parameter contains the
273-
source source. Example:
271+
Lets you create HTML ``<source>`` elements. The first parameter contains the path of the resource.
272+
Example:
274273

275274
.. literalinclude:: html_helper/015.php
276275

@@ -352,11 +351,11 @@ The following functions are available:
352351

353352
.. literalinclude:: html_helper/020.php
354353

355-
The following is a list of the pre-defined doctype choices. These are configurable,
356-
pulled from **app/Config/DocTypes.php**, or they could be over-ridden in your **.env** configuration.
354+
The following is a list of the pre-defined doctypes. These are
355+
pulled from **app/Config/DocTypes.php**, or they could be overridden in your **.env** configuration.
357356

358357
=============================== =================== ==================================================================================================================================================
359-
Document type Option Result
358+
Document type $type parameter Result
360359
=============================== =================== ==================================================================================================================================================
361360
XHTML 1.1 xhtml11 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
362361
XHTML 1.0 Strict xhtml1-strict <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

0 commit comments

Comments
 (0)