PHP Класс Horde_Themes_Css, horde

Copyright 2010-2016 Horde LLC (http://www.horde.org/) See the enclosed file COPYING for license information (LGPL). If you did not receive this file, see http://www.horde.org/licenses/lgpl21.
Автор: Michael Slusarz ([email protected])
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$_cacheid string The theme cache ID.
$_cssFiles array A list of additional stylesheet files to add to the output.
$_cssThemeFiles array A list of additional themed stylesheet files to add to the output.

Открытые методы

Метод Описание
addStylesheet ( string $file, string $url ) Adds an external stylesheet to the output.
addThemeStylesheet ( string $file ) Adds a themed stylesheet to the output.
getBaseStylesheetList ( ) : array Returns the list of base stylesheets, based on the current language and browser settings.
getStylesheetUrls ( array $opts = [] ) : array Generate the stylesheet URLs needed to display the current page.
getStylesheets ( mixed $theme = '', array $opts = [] ) : array Return the list of base stylesheets to display.
loadCssFiles ( array $files ) : string Loads CSS files, cleans up the input, and concatenates to a string.

Описание методов

addStylesheet() публичный Метод

Adds an external stylesheet to the output.
public addStylesheet ( string $file, string $url )
$file string The CSS filepath.
$url string The CSS URL.

addThemeStylesheet() публичный Метод

Adds a themed stylesheet to the output.
public addThemeStylesheet ( string $file )
$file string The stylesheet name.

getBaseStylesheetList() публичный Метод

Returns the list of base stylesheets, based on the current language and browser settings.
public getBaseStylesheetList ( ) : array
Результат array A list of base CSS files to load.

getStylesheetUrls() публичный Метод

Honors configuration choices as to stylesheet caching.
public getStylesheetUrls ( array $opts = [] ) : array
$opts array Additional options:
  - app: (string) The current application.
  - nobase: (boolean) If true, don't load base stylesheets.
  - nocache: (boolean) If true, don't load files from cache.
  - nohorde: (boolean) If true, don't load files from Horde.
  - sub: (string) A subdirectory containing additional CSS files to
         load as an overlay to the base CSS files.
  - subonly: (boolean) If true, only load the files in 'sub', not
             the default theme files.
  - theme: (string) Use this theme instead of the default.
  - themeonly: (boolean) If true, only load the theme files.
Результат array The list of URLs to display (Horde_Url objects).

getStylesheets() публичный Метод

Return the list of base stylesheets to display.
public getStylesheets ( mixed $theme = '', array $opts = [] ) : array
$theme mixed The theme to use; specify an empty value to retrieve the theme from user preferences, and false for no theme.
$opts array Additional options:
  - app: (string) The current application.
  - nobase: (boolean) If true, don't load base stylesheets.
  - nohorde: (boolean) If true, don't load files from Horde.
  - sub: (string) A subdirectory containing additional CSS files to
         load as an overlay to the base CSS files.
  - subonly: (boolean) If true, only load the files in 'sub', not
             the default theme files.
  - themeonly: (boolean) If true, only load the theme files.
Результат array An array of 2-element array arrays containing 2 keys:
  - app: (string) App of the CSS file.
  - fs: (string) Filesystem location of stylesheet.
  - uri: (string) URI of stylesheet.

loadCssFiles() публичный Метод

Loads CSS files, cleans up the input, and concatenates to a string.
Устаревший: Use Horde_Themes_Css_Compress instead.
public loadCssFiles ( array $files ) : string
$files array List of CSS files as returned from getStylesheets().
Результат string CSS data.

Описание свойств

$_cacheid защищенное свойство

The theme cache ID.
protected string $_cacheid
Результат string

$_cssFiles защищенное свойство

A list of additional stylesheet files to add to the output.
protected array $_cssFiles
Результат array

$_cssThemeFiles защищенное свойство

A list of additional themed stylesheet files to add to the output.
protected array $_cssThemeFiles
Результат array