LOADICONS
in package
Load image icons used throughout WIKINDX
Table of Contents
Methods
- __construct() : mixed
- LOADICONS
- getClass() : string
- Get the HTML IMG tag of a standard icon from its basename
- getHTML() : string
- Get the HTML IMG tag of a standard icon from its basename
- getIconForAFileExtension() : string
- Return the HTML code of an image for the file type of the file name in argument
- setReturnIcon() : string
- Create a general 'return' icon for use in the heading of various pages in order to return to the previous page.
Methods
__construct()
LOADICONS
public
__construct() : mixed
Always call $this->setupIcons() after initialization
getClass()
Get the HTML IMG tag of a standard icon from its basename
public
getClass(string $basename) : string
Parameters
- $basename : string
Return values
stringgetHTML()
Get the HTML IMG tag of a standard icon from its basename
public
getHTML(string $basename) : string
Parameters
- $basename : string
Return values
stringgetIconForAFileExtension()
Return the HTML code of an image for the file type of the file name in argument
public
getIconForAFileExtension(string $file[, bool $preview = false ]) : string
NB: The base64 code of the icons could be memoized. In practice this function is only called for the view of an individual resource, and this optimization is not useful.
Parameters
- $file : string
-
Basename of a file icon
- $preview : bool = false
-
If TRUE, display the preview message instead of the basefilename (Default is FALSE).
Tags
Return values
string —HTML link to an image
setReturnIcon()
Create a general 'return' icon for use in the heading of various pages in order to return to the previous page.
public
setReturnIcon(string $action) : string
Parameters
- $action : string