SproutCMS

This is the code documentation for the SproutCMS project

Page options:

Inherited members

class Register

This will one day have methods for various different aspects of the cms
incl. widgets, search handlers, tabs, etc.
Dare to dream

Variables

NameVisibilityDescription
$admin_controllers (static) 
$admin_tiles (static) 
$content_replace_chains (static) 
$cron_jobs (static) 
$dbtool_apis (static) 
$display_conditions (static) 
$docimports (static) 
$emailtexts (static) 
$extra_pages (static) 
$features (static) 
$front_end_controllers (static) 
$linkspecs (static) 
$moderators (static) 
$modules (static) 
$pageattrs (static) 
$rtelibraries (static) 
$search_handlers (static) 
$sitemap_generators (static) 
$widget_tiles (static) 

Functions

NameVisibilityDescription
addDbtoolsApipublic (static)Register an API test form
adminControllerspublic (static)Registers a module's shorthand controller names for the admin controller
adminTilepublic (static)Register a "tile", which is shown in the modules menu in the admin
contentReplacepublic (static)Register a method for a content replacement chain
coreContentControllerspublic (static)Register the various "content" controllers which are provided by the SproutCMS core
cronJobpublic (static)Register a method to be called for cron job processing
displayConditionpublic (static)Register a display condition (this is part of the Context Engine on widgets)
docImportpublic (static)Register a DocImport class
emailTextpublic (static)Register an email text
extraPagepublic (static)Register a type for an extra page
featurepublic (static)Register an available feature, and the root namespace where the helpers are found
frontEndControllerpublic (static)Register a front-end controller (also called a tool page)
getAdminControllerpublic (static)Converts an shorthand admin controller name to its full class name,
getAdminControllerspublic (static)Gets the list of modular admin controllers with registered shorthands
getAdminTilespublic (static)Return an array of admin tiles.
getAllCronJobspublic (static)Return all registered cron jobs
getContentReplaceMethodspublic (static)Return the methods for a given content replace chain
getCronJobspublic (static)Return the methods for a given cron job schedule
getDbtoolsApipublic (static)Return list of dbtool api tests
getDisplayConditionspublic (static)Return a list of all display condition registrations
getDocImportspublic (static)Get all `DocImport`s
getEmailTextpublic (static)Get a single registered email texts. Returns an EmailTextReg object
getEmailTextspublic (static)Get all registered email texts. Returns an array of EmailTextReg objects
getExtraPagespublic (static)Get all extra pages
getFeatureNamespacepublic (static)Return the namespace for a given feature
getFrontEndControllerspublic (static)Get all front-end controllers
getLinkspecspublic (static)Get all `LinkSpec`s
getModeratorspublic (static)Get all moderation classes
getModuleDirspublic (static)Gets a list of paths to the active modules
getModulespublic (static)Gets the list of active modules
getPageattrspublic (static)Get all extra pages
getRteLibrariespublic (static)Get all `RteLibrary`s
getSearchHandlerspublic (static)Return list of SearchHandler objects
getSitemapGenspublic (static)Get a list of all sitemap.xml generator classes
getWidgetTilespublic (static)Return an array of widget tiles for a given widget area
hasFeaturepublic (static)Is the given feature currently available?
linkspecpublic (static)Register a LinkSpec
moderatorpublic (static)Register a moderation class
modulepublic (static)Registers a module
modulespublic (static)Registers a list of modules
pageattrpublic (static)Register a type for an extra page
rteLibrarypublic (static)Register a RteLibrary class
searchHandlerpublic (static)Register search handler
sitemapGenpublic (static)Register a sitemap.xml generator class
templateVariablepublic (static)Register an helper to expose to twig templates via the 'sprout' namespace.
widgetTilepublic (static)Register a widget "tile", which is shown when adding widgets (content blocks) to a page

public addDbtoolsApi

void Register::addDbtoolsApi ( array $api );

Register an API test form

public adminControllers

void Register::adminControllers ( string $namespace , array $controllers );

Registers a module's shorthand controller names for the admin controller

public adminTile

void Register::adminTile ( string $name , string $icon , string $text , array $controllers [, int $sort_order ] );

Register a "tile", which is shown in the modules menu in the admin

A list of available icons can be found in the file sprout/media/fonts/iconfont/demo.html

public contentReplace

void Register::contentReplace ( string $chain , string $func );

Register a method for a content replacement chain

Registered method will receive one string argument and should return a string.
For the 'inner_html' chain, the input and output should be HTML

Common chains:
     inner_html      The "inside" HTML of widgets (richtext, blog content, etc)
     main_content    The main content of inner and wide templates

public coreContentControllers

void Register::coreContentControllers ( );

Register the various "content" controllers which are provided by the SproutCMS core
This will allow these controllers to have permissions (e.g. per-tab or per-record)

public cronJob

void Register::cronJob ( string $schedule , string $class , string $func );

Register a method to be called for cron job processing

By default there is only one schedule, 'daily', but it's easy to add
another schedule by duplicating the cron_daily.sh file and making the new
file call the new schedule

public displayCondition

void Register::displayCondition ( string $class , string $group , string $label );

Register a display condition (this is part of the Context Engine on widgets)

Condition classes must extend the base class Sprout\Helpers\DisplayConditions\DisplayCondition

public docImport

void Register::docImport ( mixed $ext , mixed $class , mixed $label );

Register a DocImport class

public emailText

void Register::emailText ( string $code , array $field_defs , string $default_html_view );

Register an email text

public extraPage

void Register::extraPage ( mixed $name , mixed $label );

Register a type for an extra page

public feature

void Register::feature ( string $code , string $namespace );

Register an available feature, and the root namespace where the helpers are found

Features allow the Sprout core to access code provided by modules without needing
to hard-code the namespace of these modules

public frontEndController

void Register::frontEndController ( string $name , string $label );

Register a front-end controller (also called a tool page)

public getAdminController

string Register::getAdminController ( string $shorthand );

Converts an shorthand admin controller name to its full class name,
including modular namespace

public getAdminControllers

array Register::getAdminControllers ( );

Gets the list of modular admin controllers with registered shorthands

public getAdminTiles

array Register::getAdminTiles ( );

Return an array of admin tiles.
Each tile has four keys, 'name', 'icon', 'text', and 'controllers'.

public getAllCronJobs

array Register::getAllCronJobs ( );

Return all registered cron jobs

public getContentReplaceMethods

array Register::getContentReplaceMethods ( string $chain );

Return the methods for a given content replace chain

public getCronJobs

array Register::getCronJobs ( string $schedule );

Return the methods for a given cron job schedule

public getDbtoolsApi

array Register::getDbtoolsApi ( );

Return list of dbtool api tests

public getDisplayConditions

array Register::getDisplayConditions ( );

Return a list of all display condition registrations

public getDocImports

unknown Register::getDocImports ( );

Get all `DocImport`s

public getEmailText

unknown Register::getEmailText ( mixed $code );

Get a single registered email texts. Returns an EmailTextReg object

public getEmailTexts

unknown Register::getEmailTexts ( );

Get all registered email texts. Returns an array of EmailTextReg objects

public getExtraPages

unknown Register::getExtraPages ( );

Get all extra pages

public getFeatureNamespace

string Register::getFeatureNamespace ( string $code );

Return the namespace for a given feature

public getFrontEndControllers

unknown Register::getFrontEndControllers ( );

Get all front-end controllers

public getLinkspecs

unknown Register::getLinkspecs ( );

Get all `LinkSpec`s

public getModerators

unknown Register::getModerators ( );

Get all moderation classes

public getModuleDirs

array Register::getModuleDirs ( );

Gets a list of paths to the active modules

public getModules

array Register::getModules ( );

Gets the list of active modules

public getPageattrs

unknown Register::getPageattrs ( );

Get all extra pages

public getRteLibraries

unknown Register::getRteLibraries ( );

Get all `RteLibrary`s

public getSearchHandlers

array Register::getSearchHandlers ( );

Return list of SearchHandler objects

public getSitemapGens

unknown Register::getSitemapGens ( );

Get a list of all sitemap.xml generator classes

public getWidgetTiles

array Register::getWidgetTiles ( mixed $area_name );

Return an array of widget tiles for a given widget area
Each tile has four keys, 'name', 'icon', 'text', and 'widgets'.

public hasFeature

bool Register::hasFeature ( string $code );

Is the given feature currently available?

public linkspec

void Register::linkspec ( mixed $name , mixed $label );

Register a LinkSpec

public moderator

void Register::moderator ( mixed $class_name );

Register a moderation class

public module

void Register::module ( string $name );

Registers a module

public modules

void Register::modules ( array $names );

Registers a list of modules

public pageattr

void Register::pageattr ( string $name , string $label [, string $editor ] );

Register a type for an extra page

public rteLibrary

void Register::rteLibrary ( mixed $class_name );

Register a RteLibrary class

public searchHandler

void Register::searchHandler ( string $class , string $table , array $where );

Register search handler

public sitemapGen

void Register::sitemapGen ( mixed $class_name );

Register a sitemap.xml generator class

public templateVariable

void Register::templateVariable ( string $name , mixed $item );

Register an helper to expose to twig templates via the 'sprout' namespace.

public widgetTile

void Register::widgetTile ( string $area_name , string $name , string $icon , string $text , array $widgets );

Register a widget "tile", which is shown when adding widgets (content blocks) to a page

If a tile already exists with that name, the widgets will be added to that tile

A list of available icons can be found in the file sprout/media/fonts/iconfont/demo.html