ImageLink
extends AbstractHelper
in package
Uses
RelativePathTrait
Image link view helper (extended for VuFind's theme system)
Tags
Table of Contents
- $themeInfo : ThemeInfo
- Theme information service
- __construct() : mixed
- Constructor
- __invoke() : string
- Returns an image path according the configured theme
- isRelativePath() : bool
- Is the provided src value a relative path? Returns true if this should be searched within the local theme, or false if it is an absolute path or full URL.
Properties
$themeInfo
Theme information service
protected
ThemeInfo
$themeInfo
Methods
__construct()
Constructor
public
__construct(ThemeInfo $themeInfo) : mixed
Parameters
- $themeInfo : ThemeInfo
-
Theme information service
Return values
mixed —__invoke()
Returns an image path according the configured theme
public
__invoke(string $image) : string
Parameters
- $image : string
-
image name/path
Return values
string —path, null if image not found
isRelativePath()
Is the provided src value a relative path? Returns true if this should be searched within the local theme, or false if it is an absolute path or full URL.
protected
isRelativePath(string $src) : bool
Parameters
- $src : string
-
Value to check