PageLayoutController

Script Class for Web > Layout module

Table of Contents

Properties

$id  : int
Page Id for which to make the listing
$MOD_SETTINGS  : array<string|int, mixed>
Module settings (session variable)
$pageinfo  : array<string|int, mixed>|bool
Current ids page record
$activeColPosList  : string
List of column-integers accessible to the current BE user.
$availableLanguages  : array<string|int, SiteLanguage>
$buttonBar  : ButtonBar
$colPosList  : string
List of column-integers to edit. Is set from TSconfig, default is "1,0,2,3"
$context  : PageLayoutContext|null
$current_sys_language  : int
Currently selected language for editing content elements
$iconFactory  : IconFactory
$MOD_MENU  : array<string|int, mixed>
Menu configuration
$modSharedTSconfig  : array<string|int, mixed>
Module shared TSconfig
$modTSconfig  : array<string|int, mixed>
Module TSconfig
$moduleName  : string
The name of the module
$moduleTemplate  : ModuleTemplate
$moduleTemplateFactory  : ModuleTemplateFactory
$pageRenderer  : PageRenderer
$pageRepository  : PageRepository
$searchContent  : string
$uriBuilder  : UriBuilder

Methods

__construct()  : mixed
getModuleTemplate()  : ModuleTemplate
Make the ModuleTemplate public accessible for the use in hooks.
mainAction()  : ResponseInterface
Injects the request object for the current request or subrequest As this controller goes only through the main() method, it is rather simple for now
generateMessagesForCurrentPage()  : string
Generate various messages (rendered as callouts) for the current page record (such as if the page has a special doktype).
getBackendUser()  : BackendUserAuthentication
Returns the current BE user.
getLanguageService()  : LanguageService
Returns LanguageService
getLocalizedPageTitle()  : string
getNumberOfHiddenElements()  : int
Returns the number of hidden elements (including those hidden by start/end times) on the current page (for the current sys_language)
getPageLinksWhereContentIsAlsoShownOn()  : string
Get all pages with links where the content of a page $pageId is also shown on
getShortcutTitle()  : string
Returns the shortcut title for the current page
getTargetPageIfVisible()  : array<string|int, mixed>
Returns the target page if visible
initActions()  : array<string|int, mixed>
Initializes the available actions this module provides
initializeClipboard()  : void
Initializes the clipboard for generating paste links dynamically via JavaScript after each "+ Content" symbol
isContentEditable()  : bool
Check if content can be edited by current user
isPageEditable()  : bool
Check if page can be edited by current user
main()  : void
Main function.
makeActionMenu()  : void
This creates the dropdown menu with the different actions this module is able to provide.
makeButtons()  : void
This creates the buttons for the modules
makeLanguageMenu()  : void
Make the LanguageMenu
menuConfig()  : void
Initialize menu array
renderContent()  : string
Rendering content

Properties

$id

Page Id for which to make the listing

public int $id
Internal

$MOD_SETTINGS

Module settings (session variable)

public array<string|int, mixed> $MOD_SETTINGS = []
Internal

$pageinfo

Current ids page record

public array<string|int, mixed>|bool $pageinfo
Internal

$activeColPosList

List of column-integers accessible to the current BE user.

protected string $activeColPosList

Is set from TSconfig, default is $colPosList

$colPosList

List of column-integers to edit. Is set from TSconfig, default is "1,0,2,3"

protected string $colPosList = ''

$current_sys_language

Currently selected language for editing content elements

protected int $current_sys_language

$MOD_MENU

Menu configuration

protected array<string|int, mixed> $MOD_MENU = []

$modSharedTSconfig

Module shared TSconfig

protected array<string|int, mixed> $modSharedTSconfig = []

$modTSconfig

Module TSconfig

protected array<string|int, mixed> $modTSconfig = []

$moduleName

The name of the module

protected string $moduleName = 'web_layout'

$searchContent

protected string $searchContent

Methods

mainAction()

Injects the request object for the current request or subrequest As this controller goes only through the main() method, it is rather simple for now

public mainAction(ServerRequestInterface $request) : ResponseInterface
Parameters
$request : ServerRequestInterface

the current request

Return values
ResponseInterface

the response with the content

generateMessagesForCurrentPage()

Generate various messages (rendered as callouts) for the current page record (such as if the page has a special doktype).

protected generateMessagesForCurrentPage() : string
Return values
string

HTML content with messages

getLocalizedPageTitle()

protected getLocalizedPageTitle() : string
Return values
string

$title

getNumberOfHiddenElements()

Returns the number of hidden elements (including those hidden by start/end times) on the current page (for the current sys_language)

protected getNumberOfHiddenElements(bool $isLanguageModeActive) : int
Parameters
$isLanguageModeActive : bool
Return values
int

getPageLinksWhereContentIsAlsoShownOn()

Get all pages with links where the content of a page $pageId is also shown on

protected getPageLinksWhereContentIsAlsoShownOn(int $pageId) : string
Parameters
$pageId : int
Return values
string

getShortcutTitle()

Returns the shortcut title for the current page

protected getShortcutTitle() : string
Return values
string

getTargetPageIfVisible()

Returns the target page if visible

protected getTargetPageIfVisible(array<string|int, mixed> $targetPage) : array<string|int, mixed>
Parameters
$targetPage : array<string|int, mixed>
Return values
array<string|int, mixed>

initActions()

Initializes the available actions this module provides

protected initActions() : array<string|int, mixed>
Return values
array<string|int, mixed>

the available actions

initializeClipboard()

Initializes the clipboard for generating paste links dynamically via JavaScript after each "+ Content" symbol

protected initializeClipboard(ServerRequestInterface $request) : void
Parameters
$request : ServerRequestInterface

isContentEditable()

Check if content can be edited by current user

protected isContentEditable(int $languageId) : bool
Parameters
$languageId : int
Return values
bool

isPageEditable()

Check if page can be edited by current user

protected isPageEditable(int $languageId) : bool
Parameters
$languageId : int
Return values
bool

main()

Main function.

protected main(ServerRequestInterface $request) : void

Creates some general objects and calls other functions for the main rendering of module content.

Parameters
$request : ServerRequestInterface

makeActionMenu()

This creates the dropdown menu with the different actions this module is able to provide.

protected makeActionMenu() : void

For now they are Columns and Languages.

makeButtons()

This creates the buttons for the modules

protected makeButtons(ServerRequestInterface $request) : void
Parameters
$request : ServerRequestInterface

makeLanguageMenu()

Make the LanguageMenu

protected makeLanguageMenu() : void

menuConfig()

Initialize menu array

protected menuConfig(ServerRequestInterface $request) : void
Parameters
$request : ServerRequestInterface

renderContent()

Rendering content

protected renderContent() : string
Return values
string

        
On this page

Search results