Свойство | Тип | Описание | |
---|---|---|---|
$container | The component container |
Метод | Описание | |
---|---|---|
__construct ( |
Public constructor | |
addCSS ( string $uri, string $version = null, string $type = 'text/css', string $media = null, array $attribs = [] ) : void | Add a CSS file to the page generated by the CMS | |
addCSSInline ( string $css, string $type = 'text/css' ) | Adds an inline stylesheet (inline CSS) to the page header | |
addJS ( string $uri, boolean $defer = false, boolean $async = false, string $version = null, string $type = 'text/javascript' ) : void | Add a JS script file to the page generated by the CMS. | |
addJSInline ( string $script, string $type = 'text/javascript' ) | Adds an inline JavaScript script to the page header | |
addLESS ( string $path, string $altPath = null, boolean $returnPath = false, string $version = null, string $type = 'text/css', string $media = null, array $attribs = [] ) : mixed | Compile a LESS file into CSS and add it to the page generated by the CMS. | |
getAltPaths ( string $path ) : array | Parse a fancy path definition into a path relative to the site's root. | |
loadModule ( string $moduleName, integer $style ) : string | Render a module by name | |
loadPosition ( string $position, integer $style ) : string | Returns the contents of a module position | |
parsePath ( string $path, boolean $localFile = false ) : string | Parse a fancy path definition into a path relative to the site's root, respecting template overrides, suitable for inclusion of media files. | |
route ( string $route = '' ) : string | Merges the current url with new or changed parameters. | |
sefSort ( string $text, string $field, stdClass $list ) : string | Creates a SEF compatible sort header. Standard Joomla function will add a href="#" tag, so with SEF enabled, the browser will follow the fake link instead of processing the onSubmit event; so we need a fix. |
public __construct ( |
||
$container | The component container |
public addCSS ( string $uri, string $version = null, string $type = 'text/css', string $media = null, array $attribs = [] ) : void | ||
$uri | string | A path definition understood by parsePath, e.g. media://com_example/css/foo.css |
$version | string | (optional) Version string to be added to the URL |
$type | string | MIME type of the stylesheeet |
$media | string | Media target definition of the style sheet, e.g. "screen" |
$attribs | array | Array of attributes |
Результат | void |
public addCSSInline ( string $css, string $type = 'text/css' ) | ||
$css | string | The stylesheet content to add |
$type | string | The MIME type of the script |
public addJS ( string $uri, boolean $defer = false, boolean $async = false, string $version = null, string $type = 'text/javascript' ) : void | ||
$uri | string | A path definition understood by parsePath, e.g. media://com_example/js/foo.js |
$defer | boolean | Adds the defer attribute, see above |
$async | boolean | Adds the async attribute, see above |
$version | string | (optional) Version string to be added to the URL |
$type | string | MIME type of the script |
Результат | void |
public addJSInline ( string $script, string $type = 'text/javascript' ) | ||
$script | string | The script content to add |
$type | string | The MIME type of the script |
public addLESS ( string $path, string $altPath = null, boolean $returnPath = false, string $version = null, string $type = 'text/css', string $media = null, array $attribs = [] ) : mixed | ||
$path | string | A path definition understood by parsePath pointing to the source LESS file, e.g. media://com_example/less/foo.less |
$altPath | string | A path definition understood by parsePath pointing to a precompiled CSS file, used when we can't write the generated file to the output directory, e.g. media://com_example/css/foo.css |
$returnPath | boolean | Return the URL of the generated CSS file but do not include it. If it can't be generated, false is returned and the alt files are not included |
$version | string | (optional) Version string to be added to the URL |
$type | string | MIME type of the stylesheeet |
$media | string | Media target definition of the style sheet, e.g. "screen" |
$attribs | array | Array of attributes |
Результат | mixed | True = successfully included generated CSS, False = the alternate CSS file was used, null = the source file does not exist |
public getAltPaths ( string $path ) : array | ||
$path | string | Fancy path |
Результат | array | Array of normal and alternate parsed path |
Result:
http://fobar.com/index.php?option=com_foo&view=categories&layout=tree