Horde_Themes
in package
An interface to handling Horde theme elements.
Tags
Table of Contents
Methods
- getFeedXsl() : string
- Return the location of the feed XSL file.
- img() : Horde_Themes_Image
- Return the path to an image, using the default image if the image does not exist in the current theme.
- sound() : Horde_Themes_Sound
- Return the path to a sound, using the default sound if the sound does not exist in the current theme.
- soundList() : array<string|int, mixed>
- Returns a list of available sounds.
- themeList() : array<string|int, mixed>
- Returns a list of available themes.
- viewDir() : string
- Return the view-specific directory for a Horde view.
Methods
getFeedXsl()
Return the location of the feed XSL file.
public
static getFeedXsl() : string
As of now, this file MUST live in horde/themes/default/feed-rss.xsl.
Return values
string —Path to the feed file.
img()
Return the path to an image, using the default image if the image does not exist in the current theme.
public
static img([string $name = null ][, mixed $options = array() ]) : Horde_Themes_Image
Parameters
- $name : string = null
-
The image name. If null, will return the image directory.
- $options : mixed = array()
-
Additional options. If a string, is taken to be the 'app' parameter. If an array, the following options are available:
- app: (string) Use this application instead of the current app.
- nohorde: (boolean) If true, do not fallback to horde for image.
- noview: (boolean) If true, do not load images from view-specific directories. (Since 2.4.0)
- theme: (string) Use this theme instead of the Horde default.
Return values
Horde_Themes_Image —An object which contains the URI and filesystem location of the image.
sound()
Return the path to a sound, using the default sound if the sound does not exist in the current theme.
public
static sound([string $name = null ][, mixed $options = array() ]) : Horde_Themes_Sound
Parameters
- $name : string = null
-
The sound name. If null, will return the sound directory.
- $options : mixed = array()
-
Additional options. If a string, is taken to be the 'app' parameter. If an array, the following options are available:
- app: (string) Use this application instead of the current app.
- nohorde: (boolean) If true, do not fallback to horde for sound.
- noview: (boolean) If true, do not load images from view-specific directories. (Since 2.4.0)
- theme: (string) Use this theme instead of the Horde default.
Return values
Horde_Themes_Sound —An object which contains the URI and filesystem location of the sound.
soundList()
Returns a list of available sounds.
public
static soundList([string $app = null ][, string $theme = null ]) : array<string|int, mixed>
Parameters
- $app : string = null
-
The app to search in.
- $theme : string = null
-
The theme to search in.
Return values
array<string|int, mixed> —An array of Horde_Themes_Sound objects. Keys are the base filenames.
themeList()
Returns a list of available themes.
public
static themeList() : array<string|int, mixed>
Tags
Return values
array<string|int, mixed> —Keys are theme names, values are theme descriptions.
viewDir()
Return the view-specific directory for a Horde view.
public
static viewDir(int $view) : string
Parameters
- $view : int
-
The Horde view type.
Tags
Return values
string —The directory prefix.