Overview

Packages

  • Core
    • Authentication
    • Backend
    • Cache
    • CEC
    • Chain
    • ContentType
    • Database
    • Datatype
    • Debug
    • Exception
    • Frontend
      • Search
      • URI
      • Util
    • GenericDB
      • Model
    • GUI
      • HTML
    • I18N
    • LayoutHandler
    • Log
    • Security
    • Session
    • Util
    • Validation
    • Versioning
    • XML
  • Module
    • ContentSitemapHtml
    • ContentSitemapXml
    • ContentUserForum
    • NavigationTop
  • mpAutoloaderClassMap
  • None
  • Plugin
    • ContentAllocation
    • CronjobOverview
    • FormAssistant
    • FrontendLogic
    • FrontendUsers
    • Linkchecker
    • ModRewrite
    • Newsletter
    • Repository
      • FrontendNavigation
      • KeywordDensity
    • SearchSolr
    • SmartyWrapper
    • UrlShortener
    • UserForum
    • Workflow
  • PluginManager
  • Setup
    • Form
    • GUI
    • Helper
      • Environment
      • Filesystem
      • MySQL
      • PHP
    • UpgradeJob

Classes

  • cLayoutHandler
  • cLayoutSynchronizer
  • Overview
  • Package
  • Class
  • Tree
  • Deprecated
  • Todo

Class cLayoutHandler

This class controls all layouts in filesystem.

Package: Core\LayoutHandler
Copyright: four for business AG <www.4fb.de>
License: http://www.contenido.org/license/LIZENZ.txt
Author: Rusmir Jusufovic
Located at classes/class.layout.handler.php
Methods summary
public
# __construct( integer $layoutId = 0, string $layoutCode = "", array $cfg = array(), integer $lang = 0, cDb $db = NULL )

Construct of the class

Construct of the class

Parameters

$layoutId
integer
$layoutId
$layoutCode
string
$layoutCode
$cfg
array
$cfg
$lang
integer
$lang
$db
cDb
$db
public string
# _getLayoutPath( )

Get method for Layout path

Get method for Layout path

Returns

string
public string
# _getFileName( )

Get method for Filename

Get method for Filename

Returns

string
public static boolean
# existLayout( string $layoutAlias, array $cfgClient, integer $client )

Look in layout directory if layout [$layoutAlias] directory exists

Look in layout directory if layout [$layoutAlias] directory exists

Parameters

$layoutAlias
string
$layoutAlias
$cfgClient
array
$cfgClient
$client
integer
$client

Returns

boolean
true if file exist
public
# init( integer $layoutId, string $layoutCode, array $cfg, integer $language )

Init all vars for the class

Init all vars for the class

Parameters

$layoutId
integer
$layoutId
$layoutCode
string
$layoutCode
$cfg
array
$cfg
$language
integer
$language
public string
# getLayoutName( )

Get the layout name

Get the layout name

Returns

string
layoutname
public
# initWithDbObject( cDb $dbObject )

Init class vars with values, only use for setup or upgrade

Init class vars with values, only use for setup or upgrade

Parameters

$dbObject
cDb
$dbObject
private boolean
# _makeDirectories( )

Make all directories for layout. Main directory and Layout directory

Make all directories for layout. Main directory and Layout directory

Returns

boolean
true if successfully
private boolean
# _makeDirectory( string $directory )

Make directory

Make directory

Parameters

$directory
string
$directory

Returns

boolean
true if succssesfully
private
# _setEncoding( integer $lang )

Save encoding from language.

Save encoding from language.

Parameters

$lang
integer
$lang
public boolean
# isWritable( string $fileName, string $directory )

Can write/create a file

Can write/create a file

Parameters

$fileName
string
$fileName file name
$directory
string
$directory directory where is the file

Returns

boolean
true on success else false
public boolean
# saveLayout( string $layoutCode = '' )

Save Layout

Save Layout

Parameters

$layoutCode
string
$layoutCode

Returns

boolean
true
public boolean
# saveLayoutByUpgrade( string $layoutCode = '' )

Save the layout only if layout doesn't exist in filesystem! Use it for upgrade!

Save the layout only if layout doesn't exist in filesystem! Use it for upgrade!

Parameters

$layoutCode
string
$layoutCode

Returns

boolean
private boolean
# _save( string $layoutCode = '' )

Parameters

$layoutCode
string
$layoutCode

Returns

boolean
public boolean
# eraseLayout( )

Removes this layout from the filesystem. Also deletes the version files.

Removes this layout from the filesystem. Also deletes the version files.

Returns

boolean
true on success or false on failure
public boolean
# rename( string $old, string $new )

Rename the Layout directory and layout file

Rename the Layout directory and layout file

Parameters

$old
string
$old
$new
string
$new

Returns

boolean
public string|boolean
# getLayoutCode( )

Get the contents of the file

Get the contents of the file

Returns

string|boolean
content or false
public static
# upgrade( cDb $adb, array $cfg, integer $clientId )

Save all layout in file system. Use it for upgrade.

Save all layout in file system. Use it for upgrade.

Parameters

$adb
cDb
$adb database object
$cfg
array
$cfg CONTENIDO config array
$clientId
integer
$clientId

Throws

cException
if the layout could not be saved
Properties summary
protected integer $_layoutId 0
#

The ID of the layout

The ID of the layout

protected string $_layoutCode ""
#

The code of the layout

The code of the layout

protected cDb $_db NULL
#
protected string $_layoutName ""
#

Layout name

Layout name

protected array $_cfg array()
#

The contenido cfg

The contenido cfg

protected string $_encoding
#

Encoding of the page

Encoding of the page

protected string $_layoutPath ""
#

Layout path [layout_path].layoutName/

Layout path [layout_path].layoutName/

protected string $_layoutMainPath ""
#

Main path of layouts. [layout_path].layouts

Main path of layouts. [layout_path].layouts

protected string $_fileName ""
#

File name of the layout ([layoutname].html

File name of the layout ([layoutname].html

CMS CONTENIDO 4.9.5 API documentation generated by ApiGen 2.8.0