PHP Class tl_content

Provide miscellaneous methods that are used by the data configuration array.
Inheritance: extends Backend
ファイルを表示 Open project: contao/core-bundle Class Usage Examples

Public Methods

Method Description
__construct ( ) Import the back end user object
addCteType ( array $arrRow ) : string Add the type of content element
checkPermission ( ) Check permissions to edit table tl_content
deleteElement ( array $row, string $href, string $label, string $title, string $icon, string $attributes ) : string Return the delete content element button
editAlias ( DataContainer $dc ) : string Return the edit alias wizard
editArticle ( DataContainer $dc ) : string Return the edit article teaser wizard
editArticleAlias ( DataContainer $dc ) : string Return the edit article alias wizard
editForm ( DataContainer $dc ) : string Return the edit form wizard
editModule ( DataContainer $dc ) : string Return the edit module wizard
extractVimeoId ( mixed $varValue, DataContainer $dc ) : mixed Extract the Vimeo ID from an URL
extractYouTubeId ( mixed $varValue, DataContainer $dc ) : mixed Extract the YouTube ID from an URL
getAlias ( ) : array Get all content elements and return them as array (content element alias)
getArticleAlias ( DataContainer $dc ) : array Get all articles and return them as array (article alias)
getArticles ( DataContainer $dc ) : array Get all articles and return them as array (article teaser)
getContentElementGroup ( string $element ) : string Return the group of a content element
getContentElements ( ) : array Return all content elements as array
getElementTemplates ( DataContainer $dc ) : array Return all content element templates as array
getForms ( ) : array Get all forms and return them as array
getGalleryTemplates ( ) : array Return all gallery templates as array
getModules ( ) : array Get all modules and return them as array
listImportWizard ( ) : string Add a link to the list items import wizard
pagePicker ( DataContainer $dc ) : string Return the link picker wizard
setMultiSrcFlags ( mixed $varValue, DataContainer $dc ) : mixed Dynamically add flags to the "multiSRC" field
setRteSyntax ( mixed $varValue, DataContainer $dc ) : string Dynamically set the ace syntax
setSingleSrcFlags ( mixed $varValue, DataContainer $dc ) : mixed Dynamically add flags to the "singleSRC" field
showJsLibraryHint ( $dc ) Show a hint if a JavaScript library needs to be included in the page layout
storeFileMetaInformation ( mixed $varValue, DataContainer $dc ) : mixed Pre-fill the "alt" and "caption" fields with the file meta data
tableImportWizard ( ) : string Add a link to the table items import wizard
toggleIcon ( array $row, string $href, string $label, string $title, string $icon, string $attributes ) : string Return the "toggle visibility" button
toggleVisibility ( integer $intId, boolean $blnVisible, DataContainer $dc = null ) Toggle the visibility of an element

Protected Methods

Method Description
checkAccessToElement ( integer $id, array $pagemounts, boolean $blnIsPid = false ) Check access to a particular content element

Method Details

__construct() public method

Import the back end user object
public __construct ( )

addCteType() public method

Add the type of content element
public addCteType ( array $arrRow ) : string
$arrRow array
return string

checkAccessToElement() protected method

Check access to a particular content element
protected checkAccessToElement ( integer $id, array $pagemounts, boolean $blnIsPid = false )
$id integer
$pagemounts array
$blnIsPid boolean

checkPermission() public method

Check permissions to edit table tl_content
public checkPermission ( )

deleteElement() public method

Return the delete content element button
public deleteElement ( array $row, string $href, string $label, string $title, string $icon, string $attributes ) : string
$row array
$href string
$label string
$title string
$icon string
$attributes string
return string

editAlias() public method

Return the edit alias wizard
public editAlias ( DataContainer $dc ) : string
$dc DataContainer
return string

editArticle() public method

Return the edit article teaser wizard
public editArticle ( DataContainer $dc ) : string
$dc DataContainer
return string

editArticleAlias() public method

Return the edit article alias wizard
public editArticleAlias ( DataContainer $dc ) : string
$dc DataContainer
return string

editForm() public method

Return the edit form wizard
public editForm ( DataContainer $dc ) : string
$dc DataContainer
return string

editModule() public method

Return the edit module wizard
public editModule ( DataContainer $dc ) : string
$dc DataContainer
return string

extractVimeoId() public method

Extract the Vimeo ID from an URL
public extractVimeoId ( mixed $varValue, DataContainer $dc ) : mixed
$varValue mixed
$dc DataContainer
return mixed

extractYouTubeId() public method

Extract the YouTube ID from an URL
public extractYouTubeId ( mixed $varValue, DataContainer $dc ) : mixed
$varValue mixed
$dc DataContainer
return mixed

getAlias() public method

Get all content elements and return them as array (content element alias)
public getAlias ( ) : array
return array

getArticleAlias() public method

Get all articles and return them as array (article alias)
public getArticleAlias ( DataContainer $dc ) : array
$dc DataContainer
return array

getArticles() public method

Get all articles and return them as array (article teaser)
public getArticles ( DataContainer $dc ) : array
$dc DataContainer
return array

getContentElementGroup() public method

Return the group of a content element
public getContentElementGroup ( string $element ) : string
$element string
return string

getContentElements() public method

Return all content elements as array
public getContentElements ( ) : array
return array

getElementTemplates() public method

Return all content element templates as array
public getElementTemplates ( DataContainer $dc ) : array
$dc DataContainer
return array

getForms() public method

Get all forms and return them as array
public getForms ( ) : array
return array

getGalleryTemplates() public method

Return all gallery templates as array
public getGalleryTemplates ( ) : array
return array

getModules() public method

Get all modules and return them as array
public getModules ( ) : array
return array

listImportWizard() public method

Add a link to the list items import wizard
public listImportWizard ( ) : string
return string

pagePicker() public method

Return the link picker wizard
public pagePicker ( DataContainer $dc ) : string
$dc DataContainer
return string

setMultiSrcFlags() public method

Dynamically add flags to the "multiSRC" field
public setMultiSrcFlags ( mixed $varValue, DataContainer $dc ) : mixed
$varValue mixed
$dc DataContainer
return mixed

setRteSyntax() public method

Dynamically set the ace syntax
public setRteSyntax ( mixed $varValue, DataContainer $dc ) : string
$varValue mixed
$dc DataContainer
return string

setSingleSrcFlags() public method

Dynamically add flags to the "singleSRC" field
public setSingleSrcFlags ( mixed $varValue, DataContainer $dc ) : mixed
$varValue mixed
$dc DataContainer
return mixed

showJsLibraryHint() public method

Show a hint if a JavaScript library needs to be included in the page layout
public showJsLibraryHint ( $dc )

storeFileMetaInformation() public method

Pre-fill the "alt" and "caption" fields with the file meta data
public storeFileMetaInformation ( mixed $varValue, DataContainer $dc ) : mixed
$varValue mixed
$dc DataContainer
return mixed

tableImportWizard() public method

Add a link to the table items import wizard
public tableImportWizard ( ) : string
return string

toggleIcon() public method

Return the "toggle visibility" button
public toggleIcon ( array $row, string $href, string $label, string $title, string $icon, string $attributes ) : string
$row array
$href string
$label string
$title string
$icon string
$attributes string
return string

toggleVisibility() public method

Toggle the visibility of an element
public toggleVisibility ( integer $intId, boolean $blnVisible, DataContainer $dc = null )
$intId integer
$blnVisible boolean
$dc DataContainer