Class SGL_BlockLoader

Description

BlockLoader manages units of content that can be dynamically positioned in a page's left or right columns.

Located in /SGL/BlockLoader.php (line 50)


	
			
Variable Summary
Method Summary
 void SGL_BlockLoader ( $sectionId)
 array render ( &$output)
 void _buildBlocks ()
 void _loadBlocks ([ $getAll = true])
 void _sort ()
Variables
array $aBlocks = array() (line 69)

Array of processed blocks

Left/right blocks stored as $this->aBlocks['left'], $this->aBlocks['right'].

  • access: public
array $_aData = array() (line 58)

Temporary container for processing blocks.

  • access: private
int $_currentSectionId = 0 (line 86)

SectionId is currently roughtly equivalent to page id.

  • todo: change to pageId, also rename section table
  • access: private
int $_rid = 0 (line 77)

The role id, used so blocks can be cached per role.

  • access: private
Methods
Constructor SGL_BlockLoader (line 94)

Constructor - sets the sectionId.

  • access: public
void SGL_BlockLoader ( $sectionId)
  • $sectionId
render (line 110)

Initialises Block Mgr, loads blocks into temporary array $_aData for later processing.

  • return: array of block objects
  • author: Andy Crain <apcrain@fuse.net>>
  • access: private
array render ( &$output)
  • &$output
_buildBlocks (line 186)

With block structures in place, block contents are built.

Each block is a class in the modules/block/classes/blocks directory, containing static HTML or dynamic content

  • access: private
void _buildBlocks ()
_loadBlocks (line 144)

Loads blocks from DB.

  • access: private
void _loadBlocks ([ $getAll = true])
  • $getAll
_sort (line 236)

Sorts tmp array $_aData into order within block positions.

easier to manage in Controller

  • access: private
void _sort ()

Documentation generated on Tue, 23 Feb 2010 18:14:28 +0000 by phpDocumentor 1.4.3