SVG_Icon
Handles File Icon SVGs
Tags
Table of Contents
- get() : string|false
- Get the SVG Icon.
- get_file_extension_icon() : string
- Get file extension icon.
- render() : mixed
- Renders the SVG Icon.
- sanitize_svg() : string
- Sanitize the HTML markup of an SVG
Methods
get()
Get the SVG Icon.
public
static get(string $key[, array<string|int, mixed> $classes = [] ][, mixed $fill_color = '' ]) : string|false
Parameters
- $key : string
- $classes : array<string|int, mixed> = []
- $fill_color : mixed = ''
Tags
Return values
string|false —get_file_extension_icon()
Get file extension icon.
public
static get_file_extension_icon(string $extension) : string
Parameters
- $extension : string
Tags
Return values
string —render()
Renders the SVG Icon.
public
static render(string $key[, array<string|int, mixed> $classes = [] ][, mixed $fill_color = '' ]) : mixed
Parameters
- $key : string
- $classes : array<string|int, mixed> = []
- $fill_color : mixed = ''
Tags
Return values
mixed —sanitize_svg()
Sanitize the HTML markup of an SVG
public
static sanitize_svg(string $svg) : string
Parameters
- $svg : string
-
The markup to be sanitized
Tags
Return values
string —The sanitize markup