JDocument/ construct: Difference between revisions
From Joomla! Documentation
m removing red link to edit, no existant pages |
m preparing for archive only |
||
| Line 69: | Line 69: | ||
===Examples=== | ===Examples=== | ||
=== Code Examples === | |||
<dpl> | <dpl> | ||
noresultsheader=\n | noresultsheader=\n | ||
category=__construct | category=__construct | ||
category=JDocument | category=JDocument | ||
namespace=CodeExample | |||
category=MethodExample | category=MethodExample | ||
include=* | include=* | ||
Latest revision as of 00:29, 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() | $options Associative array of options |
Defined in
libraries/joomla/document/document.php
Importing
jimport( 'joomla.document.document' );
Source Body
function __construct( $options = array())
{
parent::__construct();
if (array_key_exists('lineend', $options)) {
$this->setLineEnd($options['lineend']);
}
if (array_key_exists('charset', $options)) {
$this->setCharset($options['charset']);
}
if (array_key_exists('language', $options)) {
$this->setLanguage($options['language']);
}
if (array_key_exists('direction', $options)) {
$this->setDirection($options['direction']);
}
if (array_key_exists('tab', $options)) {
$this->setTab($options['tab']);
}
if (array_key_exists('link', $options)) {
$this->setLink($options['link']);
}
if (array_key_exists('base', $options)) {
$this->setBase($options['base']);
}
}
[<! removed edit link to red link >] <! removed transcluded page call, red link never existed >
Examples
Code Examples