JRouter/ construct: Difference between revisions
From Joomla! Documentation
New page: ===Description===
Class constructor
<span class="editsection" style="font-size:76%;">
<nowiki>[</nowiki>Edit Descripton<nowiki>]</nowiki>
</span>
... |
m preparing for archive only |
||
| (2 intermediate revisions by 2 users not shown) | |||
| Line 3: | Line 3: | ||
<span class="editsection" style="font-size:76%;"> | <span class="editsection" style="font-size:76%;"> | ||
<nowiki>[< | <nowiki>[<! removed edit link to red link >]</nowiki> | ||
</span> | </span> | ||
<! removed transcluded page call, red link never existed > | |||
===Syntax=== | ===Syntax=== | ||
| Line 31: | Line 31: | ||
function __construct($options = array()) | function __construct($options = array()) | ||
{ | { | ||
if (array_key_exists('mode', $options)) { | if(array_key_exists('mode', $options)) { | ||
$this->_mode = $options['mode']; | $this->_mode = $options['mode']; | ||
} else { | } else { | ||
| Line 40: | Line 40: | ||
<span class="editsection" style="font-size:76%;"> | <span class="editsection" style="font-size:76%;"> | ||
<nowiki>[< | <nowiki>[<! removed edit link to red link >]</nowiki> | ||
</span> | </span> | ||
<! removed transcluded page call, red link never existed > | |||
===Examples=== | ===Examples=== | ||
=== Code Examples === | |||
<dpl> | <dpl> | ||
noresultsheader=\n | noresultsheader=\n | ||
category=__construct | category=__construct | ||
category=JRouter | category=JRouter | ||
namespace=CodeExample | |||
category=MethodExample | category=MethodExample | ||
include=* | include=* | ||
format= ,,, | format= ,,, | ||
</dpl> | </dpl> | ||
[[Category:Archived pages API15]] | |||
Latest revision as of 01:05, 25 March 2017
Description
Class constructor
[<! removed edit link to red link >]
<! removed transcluded page call, red link never existed >
Syntax
__construct($options=array())
| Parameter Name | Default Value | Description |
|---|---|---|
| $options | array() |
Defined in
libraries/joomla/application/router.php
Importing
jimport( 'joomla.application.router' );
Source Body
function __construct($options = array())
{
if(array_key_exists('mode', $options)) {
$this->_mode = $options['mode'];
} else {
$this->_mode = JROUTER_MODE_RAW;
}
}
[<! removed edit link to red link >] <! removed transcluded page call, red link never existed >
Examples
Code Examples