OnlineMediaHelperInterface

interface \TYPO3\CMS\Core\Resource\OnlineMedia\Helpers\OnlineMediaHelperInterface

Interface OnlineMediaInterface

Table of Contents

Methods

__construct()  : mixed
Constructor
getMetaData()  : array
Get meta data for OnlineMedia item
getOnlineMediaId()  : string
Get Online Media item id
getPreviewImage()  : string
Get local absolute file path to preview image
getPublicUrl()  : string|null
Get public url
transformUrlToFile()  : File|null
Try to transform given URL to a File

Methods

__construct()

Constructor

public __construct(string $extension) : mixed

Parameters

$extension : string

file extension bind to the OnlineMedia helper

getMetaData()

Get meta data for OnlineMedia item

public getMetaData(File $file) : array

See $GLOBALS[TCA][sys_file_metadata][columns] for possible fields to fill/use

Parameters

$file : File

Return values

array —

with metadata

getOnlineMediaId()

Get Online Media item id

public getOnlineMediaId(File $file) : string

Parameters

$file : File

Return values

string

getPreviewImage()

Get local absolute file path to preview image

public getPreviewImage(File $file) : string

Return an empty string when no preview image is available

Parameters

$file : File

Return values

string

getPublicUrl()

Get public url

public getPublicUrl(File $file[, bool $relativeToCurrentScript = false ]) : string|null

Return NULL if you want to use core default behaviour

Parameters

$file : File
$relativeToCurrentScript : bool = false

Deprecated since TYPO3 v11, will be removed in TYPO3 v12.0

Return values

string|null

transformUrlToFile()

Try to transform given URL to a File

public transformUrlToFile(string $url, Folder $targetFolder) : File|null

Parameters

$url : string
$targetFolder : Folder

Return values

File|null
On this page