ContentBox Core API 1.6.0

contentbox.plugins
Class CBHelper

WEB-INF.cftags.component
        extended by coldbox.system.FrameworkSupertype
            extended by coldbox.system.Plugin
                extended by contentbox.plugins.CBHelper

public class CBHelper
extends coldbox.system.Plugin

******************************************************************************* ContentBox - A Modular Content Platform Copyright 2012 by Luis Majano and Ortus Solutions, Corp www.gocontentbox.org | www.luismajano.com | www.ortussolutions.com ******************************************************************************* Apache License, Version 2.0 Copyright Since [2012] [Luis Majano and Ortus Solutions,Corp] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ******************************************************************************* This is the ContentBox UI helper class that is injected by the CBRequest interceptor

Property Summary
Type Property & Description Default Serializable Required
 any authorService


Attributes:
  • inject = id:authorService@cb
true false
 any categoryService


Attributes:
  • inject = id:categoryService@cb
true false
 any commentService


Attributes:
  • inject = id:commentService@cb
true false
 any contentStoreService


Attributes:
  • inject = id:contentStoreService@cb
true false
 any entryService


Attributes:
  • inject = id:entryService@cb
true false
 any minifier


Attributes:
  • inject = coldbox:myplugin:JSMin@contentbox
true false
 any mobileDetector


Attributes:
  • inject = id:mobileDetector@cb
true false
 any moduleService


Attributes:
  • inject = id:moduleService@cb
true false
 any pageService


Attributes:
  • inject = id:pageService@cb
true false
 any widgetService


Attributes:
  • inject = id:widgetService@cb
true false
 
Constructor Summary
init(any controller)
 
Method Summary
 any GETAUTHORSERVICE()
 any GETCATEGORYSERVICE()
 any GETCOMMENTSERVICE()
 any GETCONTENTSTORESERVICE()
 any GETENTRYSERVICE()
 any GETMOBILEDETECTOR()
 any GETMODULESERVICE()
 any GETPAGESERVICE()
 any GETWIDGETSERVICE()
 CBHelper SETAUTHORSERVICE(any authorService)
 CBHelper SETCATEGORYSERVICE(any categoryService)
 CBHelper SETCOMMENTSERVICE(any commentService)
 CBHelper SETCONTENTSTORESERVICE(any contentStoreService)
 CBHelper SETENTRYSERVICE(any entryService)
 CBHelper SETMINIFIER(any minifier)
 CBHelper SETMOBILEDETECTOR(any mobileDetector)
 CBHelper SETMODULESERVICE(any moduleService)
 CBHelper SETPAGESERVICE(any pageService)
 CBHelper SETWIDGETSERVICE(any widgetService)
 any adminRoot()
 any breadCrumbs([any page], [any separator='>'])
          Create breadcrumbs for a page
private any buildMenu([any pageRecords], [any excludes=''], [any type='ul'], [any separator=''], [boolean showNone='true'], [any levels='1'], [numeric currentLevel='1'], [any parentClass='parent'], [any activeClass='active'], [any activeShowChildren='false'])
          *********************************** PRIVATE ********************************************
 any buildModuleLink(string module, string linkTo, [any queryString=''], [boolean ssl='false'])
          Build out ContentBox module links
 boolean categoryFilterExists()
 any contentStore(any slug, [any defaultValue=''])
          Get a published content store and return its latest active content
 any contentStoreObject(any slug)
          Get a content store object by slug, if not found it returns null
 any customHTML(any slug, [any defaultValue=''])
          Get a published custom HTML content pieces by slug: DEPRECATED, use contentStore() instead
 any event(any state, [struct data='[runtime expression]'])
 any getBlogEntryPoint()
 any getCategoryFilter()
 array getCommentErrors()
 any getContentBoxCodeName()
 any getContentBoxCodeNameURL()
 any getContentBoxVersion()
 any getCurrentCategories()
 any getCurrentComments()
 any getCurrentCommentsCount()
 struct getCurrentCustomFields()
 any getCurrentEntries()
 any getCurrentEntriesCount()
 any getCurrentEntry()
 any getCurrentPage()
 any getCustomField(any key, [any defaultValue])
 any getDayFilter()
 any getFlash()
          Return the current system flash scope
 any getHomePage()
 any getMaintenanceMessage()
 any getMinifier()
 any getMissingPage()
 any getMonthFilter()
 SearchResults getSearchResults()
 any getSearchResultsContent()
 any getSearchTerm()
 any getWidget(any name)
          Return a widget object
 any getYearFilter()
 boolean isArchivesView()
 boolean isBlogView()
 boolean isCommentFormError()
 any isCommentsEnabled([any content])
          Determines if site comments are enabled and if the entry accepts comments
 boolean isEntryView()
 boolean isIndexView()
 boolean isMobile()
          Detects if the incoming request is from a mobile device or NOT
 boolean isPageView([any page=''])
          Determine if you are in the page view
 boolean isPrintFormat()
 boolean isSearchView()
 any layoutName()
 any layoutRoot()
 any layoutSetting(any key, [any value])
          Get a layout setting
 any linkAdmin([any event=''])
          Link to the admin event An optional event to link to
 any linkAdminLogin()
          Link to the admin login
 any linkAdminLogout()
          Link to the admin logout
 any linkArchive([any year], [any month], [any day], [boolean ssl='false'])
          Link to a specific filtered archive of entries
 any linkBlog()
          Create a link to your site blog
 any linkCategory(any category, [boolean ssl='false'])
          Link to a specific filtered category view of blog entries
 any linkComment(any comment, [boolean ssl='false'])
          Create a link to a specific comment in a page or in an entry
 any linkCommentPost(any content, [boolean ssl='false'])
          Link to the commenting post action, this is where comments are submitted to
 any linkComments(any content, [boolean ssl='false'])
          Create a link to an entry's or page's comments section
 any linkContent(any content, [boolean ssl='false'], [any format='html'])
          Link to a specific content object
 any linkContentSearch([boolean ssl='false'])
          Link to the content search route
 any linkEntry(any entry, [boolean ssl='false'], [any format='html'])
          Link to a specific blog entry's page
 any linkEntryWithSlug(any slug, [boolean ssl='false'], [any format='html'])
          Link to a specific entry's page using a slug only
 any linkHome()
          Create a link to your site root or home page entry point for your blog
 any linkPage(any page, [boolean ssl='false'], [any format='html'])
          Link to a specific page
 any linkPageRSS([any category], [boolean comments='false'], [any page], [boolean ssl='false'])
          Link to the ContentBox Page RSS Feeds
 any linkPageWithSlug(any slug, [boolean ssl='false'], [any format='html'])
          Link to a specific page using a slug only
 any linkRSS([any category], [any comments='false'], [any entry], [boolean ssl='false'])
          Link to RSS feeds that ContentBox generates, by default it is the recent updates feed
 any linkSearch([boolean ssl='false'])
          Link to the search route for this blog
 any linkSelf()
          Create a link to the current page/entry you are on
 any linkSiteRSS([any category], [boolean comments='false'], [string slug], [boolean ssl='false'])
          Link to the ContentBox Site RSS Feeds
 any linkToParentPage([any page], [any text=''])
          Create an href to a page's parent
 any mainView()
          Render the incoming event's main view, basically a proxy to ColdBox's renderView()
 any minify(any assets)
          Prepare source(s) statements using our fabulous jsmin compressor
 CBHelper minifyClearCache()
 CBHelper minifyToHead(any assets)
          Prepare source(s) statements using our fabulous jsmin compressor and send them to the head section
 any quickAvatar(any author, [numeric size='25'])
          Renders out an author's avatar
 any quickCategories([any template='category'], [any collectionAs='category'], [any args='[runtime expression]'])
          Render out categories anywhere using ColdBox collection rendering
 any quickCategoryLinks(any entry)
 any quickCommentForm(any content)
          quickCommentForm will build a standard ContentBox Comment Form according to the CommentForm widget
 any quickComments([any template='comment'], [any collectionAs='comment'], [any args='[runtime expression]'])
          Render out comments anywhere using ColdBox collection rendering
 any quickCustomFields()
          Render out custom fields for the current content
 any quickEntries([any template='entry'], [any collectionAs='entry'], [any args='[runtime expression]'])
          Render out entries in the home page by using our ColdBox collection rendering
 any quickEntry([any template='entry'], [any collectionAs='entry'], [any args='[runtime expression]'])
          Render out an entry using your pre-defined 'entry' template
 any quickLayout(any layout, [any view=''], [any module='contentbox'], [any args='[runtime expression]'], [any viewModule=''], [any prePostExempt='false'])
          QuickLayout is a proxy to ColdBox's renderLayout method with the addition of prefixing the location of the layout according to the layout theme you are using
 any quickPaging()
          Render out paging for blog entries only
 any quickSearchForm()
          quickSearchForm will build a standard ContentBox Content Search Form according to the SearchForm widget
 any quickSearchPaging()
          Render out paging for search content
 any quickView(any view, [any cache='false'], [any cacheTimeout], [any cacheLastAccessTimeout], [any cacheSuffix], [any module='contentbox'], [any args], [any collection], [any collectionAs], [any prepostExempt])
          QuickView is a proxy to ColdBox's renderview method with the addition of prefixing the location of the view according to the layout theme you are using
 any rootMenu([any excludes=''], [any type='ul'], [any separator=''], [any levels='1'], [any parentClass='parent'], [any activeClass='active'])
          Render out a quick menu for root level pages
 boolean searchTermExists()
private any sep()
          Get the site URL separator
 any setNextModuleEvent(string module, [string event], [any queryString=''], [boolean addToken='false'], [any persist], [struct persistStruct], [boolean ssl='false'], [boolean postProcessExempt='false'], [numeric statusCode])
          SetNextEvent For ContentBox Modules
 any setting(any key, [any value])
 any siteBaseURL()
 any siteDescription()
 any siteEmail()
 any siteKeywords()
 any siteName()
 any siteOutgoingEmail()
 any siteRoot()
 any siteTagLine()
 any stripHTML(any stringTarget)
          utility to strip HTML
 any subPageMenu([any page], [any excludes=''], [any type='ul'], [any separator=''], [boolean showNone='true'], [any levels='1'], [any parentClass='parent'], [any activeClass='active'], [any activeShowChildren='false'])
          Create a sub page menu for a given page or current page
 any widget(any name, [struct args='[runtime expression]'])
          Execute a widget's renderit method
 any widgetRoot()
 
Methods inherited from class coldbox.system.Plugin
getPluginDescription, getPluginName, getPluginVersion, getRequestCollection, getRequestContext, getpluginAuthor, getpluginAuthorURL, getpluginPath, setPluginDescription, setPluginName, setPluginVersion, setpluginAuthor, setpluginAuthorURL
 
Methods inherited from class coldbox.system.FrameworkSupertype
$abort, $dump, $htmlhead, $include, $rethrow, $throw, addAsset, announceInterception, getColdboxOCM, getController, getDatasource, getDebugMode, getInterceptor, getMailService, getMailSettings, getMemento, getModel, getModuleSettings, getMyPlugin, getNewMail, getPlugin, getResource, getSetting, getSettingStructure, getSettingsBean, getValidationManager, getfwLocale, includeUDF, loadGlobalUDFLibraries, locateDirectoryPath, locateFilePath, persistVariables, populateModel, relocate, renderExternalView, renderLayout, renderView, runEvent, setDebugMode, setNextEvent, setNextRoute, setSetting, setfwLocale, settingExists, validateModel
 
Methods inherited from class WEB-INF.cftags.component
None
 

Constructor Detail

init

public init(any controller)

Parameters:
controller
Property Detail

authorService

any authorService

Attributes:
inject - id:authorService@cb
required - false
serializable - true
default -

categoryService

any categoryService

Attributes:
inject - id:categoryService@cb
required - false
serializable - true
default -

commentService

any commentService

Attributes:
inject - id:commentService@cb
required - false
serializable - true
default -

contentStoreService

any contentStoreService

Attributes:
inject - id:contentStoreService@cb
required - false
serializable - true
default -

entryService

any entryService

Attributes:
inject - id:entryService@cb
required - false
serializable - true
default -

minifier

any minifier

Attributes:
inject - coldbox:myplugin:JSMin@contentbox
required - false
serializable - true
default -

mobileDetector

any mobileDetector

Attributes:
inject - id:mobileDetector@cb
required - false
serializable - true
default -

moduleService

any moduleService

Attributes:
inject - id:moduleService@cb
required - false
serializable - true
default -

pageService

any pageService

Attributes:
inject - id:pageService@cb
required - false
serializable - true
default -

widgetService

any widgetService

Attributes:
inject - id:widgetService@cb
required - false
serializable - true
default -

Method Detail

GETAUTHORSERVICE

public any GETAUTHORSERVICE()


GETCATEGORYSERVICE

public any GETCATEGORYSERVICE()


GETCOMMENTSERVICE

public any GETCOMMENTSERVICE()


GETCONTENTSTORESERVICE

public any GETCONTENTSTORESERVICE()


GETENTRYSERVICE

public any GETENTRYSERVICE()


GETMOBILEDETECTOR

public any GETMOBILEDETECTOR()


GETMODULESERVICE

public any GETMODULESERVICE()


GETPAGESERVICE

public any GETPAGESERVICE()


GETWIDGETSERVICE

public any GETWIDGETSERVICE()


SETAUTHORSERVICE

public CBHelper SETAUTHORSERVICE(any authorService)

Parameters:
authorService

SETCATEGORYSERVICE

public CBHelper SETCATEGORYSERVICE(any categoryService)

Parameters:
categoryService

SETCOMMENTSERVICE

public CBHelper SETCOMMENTSERVICE(any commentService)

Parameters:
commentService

SETCONTENTSTORESERVICE

public CBHelper SETCONTENTSTORESERVICE(any contentStoreService)

Parameters:
contentStoreService

SETENTRYSERVICE

public CBHelper SETENTRYSERVICE(any entryService)

Parameters:
entryService

SETMINIFIER

public CBHelper SETMINIFIER(any minifier)

Parameters:
minifier

SETMOBILEDETECTOR

public CBHelper SETMOBILEDETECTOR(any mobileDetector)

Parameters:
mobileDetector

SETMODULESERVICE

public CBHelper SETMODULESERVICE(any moduleService)

Parameters:
moduleService

SETPAGESERVICE

public CBHelper SETPAGESERVICE(any pageService)

Parameters:
pageService

SETWIDGETSERVICE

public CBHelper SETWIDGETSERVICE(any widgetService)

Parameters:
widgetService

adminRoot

public any adminRoot()


breadCrumbs

public any breadCrumbs([any page], [any separator='>'])
Create breadcrumbs for a page

Parameters:
page - Optional page to create link for, else look for current page
separator - Breadcrumb separator

buildMenu

private any buildMenu([any pageRecords], [any excludes=''], [any type='ul'], [any separator=''], [boolean showNone='true'], [any levels='1'], [numeric currentLevel='1'], [any parentClass='parent'], [any activeClass='active'], [any activeShowChildren='false'])
*********************************** PRIVATE ********************************************

Parameters:
pageRecords
excludes
type
separator
showNone
levels
currentLevel
parentClass
activeClass
activeShowChildren

buildModuleLink

public any buildModuleLink(string module, string linkTo, [any queryString=''], [boolean ssl='false'])
Build out ContentBox module links

Parameters:
module - The module to link this URL to
linkTo - The handler action combination to link to
queryString - The query string to append in SES format
ssl - Create the link in SSL or not

categoryFilterExists

public boolean categoryFilterExists()


contentStore

public any contentStore(any slug, [any defaultValue=''])
Get a published content store and return its latest active content

Parameters:
slug - The content slug to retrieve
defaultValue - The default value to use if the content element not found.

contentStoreObject

public any contentStoreObject(any slug)
Get a content store object by slug, if not found it returns null.

Parameters:
slug - The content slug to retrieve

customHTML

public any customHTML(any slug, [any defaultValue=''])
Get a published custom HTML content pieces by slug: DEPRECATED, use contentStore() instead

Parameters:
slug - The content slug to retrieve
defaultValue - The default value to use if custom html element not found.

event

public any event(any state, [struct data='[runtime expression]'])

Parameters:
state
data

getBlogEntryPoint

public any getBlogEntryPoint()


getCategoryFilter

public any getCategoryFilter()


getCommentErrors

public array getCommentErrors()


getContentBoxCodeName

public any getContentBoxCodeName()


getContentBoxCodeNameURL

public any getContentBoxCodeNameURL()


getContentBoxVersion

public any getContentBoxVersion()


getCurrentCategories

public any getCurrentCategories()


getCurrentComments

public any getCurrentComments()


getCurrentCommentsCount

public any getCurrentCommentsCount()


getCurrentCustomFields

public struct getCurrentCustomFields()


getCurrentEntries

public any getCurrentEntries()


getCurrentEntriesCount

public any getCurrentEntriesCount()


getCurrentEntry

public any getCurrentEntry()


getCurrentPage

public any getCurrentPage()


getCustomField

public any getCustomField(any key, [any defaultValue])

Parameters:
key
defaultValue

getDayFilter

public any getDayFilter()


getFlash

public any getFlash()
Return the current system flash scope


getHomePage

public any getHomePage()


getMaintenanceMessage

public any getMaintenanceMessage()


getMinifier

public any getMinifier()


getMissingPage

public any getMissingPage()


getMonthFilter

public any getMonthFilter()


getSearchResults

public SearchResults getSearchResults()


getSearchResultsContent

public any getSearchResultsContent()


getSearchTerm

public any getSearchTerm()


getWidget

public any getWidget(any name)
Return a widget object

Parameters:
name - The name of the installed widget to return

getYearFilter

public any getYearFilter()


isArchivesView

public boolean isArchivesView()


isBlogView

public boolean isBlogView()


isCommentFormError

public boolean isCommentFormError()


isCommentsEnabled

public any isCommentsEnabled([any content])
Determines if site comments are enabled and if the entry accepts comments

Parameters:
content - The entry or page content to validate comments also with

isEntryView

public boolean isEntryView()


isIndexView

public boolean isIndexView()


isMobile

public boolean isMobile()
Detects if the incoming request is from a mobile device or NOT.


isPageView

public boolean isPageView([any page=''])
Determine if you are in the page view

Parameters:
page - Optional page slug to determine if you are in that page or not.

isPrintFormat

public boolean isPrintFormat()


isSearchView

public boolean isSearchView()


layoutName

public any layoutName()


layoutRoot

public any layoutRoot()


layoutSetting

public any layoutSetting(any key, [any value])
Get a layout setting

Parameters:
key - The name of the layout setting
value - The default value if the layout setting does not exist

linkAdmin

public any linkAdmin([any event=''])
Link to the admin event An optional event to link to

Parameters:
event

linkAdminLogin

public any linkAdminLogin()
Link to the admin login


linkAdminLogout

public any linkAdminLogout()
Link to the admin logout


linkArchive

public any linkArchive([any year], [any month], [any day], [boolean ssl='false'])
Link to a specific filtered archive of entries

Parameters:
year - The year of the archive
month - The month of the archive
day - The day of the archive
ssl

linkBlog

public any linkBlog()
Create a link to your site blog


linkCategory

public any linkCategory(any category, [boolean ssl='false'])
Link to a specific filtered category view of blog entries

Parameters:
category - The category object to link to
ssl

linkComment

public any linkComment(any comment, [boolean ssl='false'])
Create a link to a specific comment in a page or in an entry

Parameters:
comment - The comment to link to
ssl

linkCommentPost

public any linkCommentPost(any content, [boolean ssl='false'])
Link to the commenting post action, this is where comments are submitted to

Parameters:
content - The entry or page to link to its comments
ssl

linkComments

public any linkComments(any content, [boolean ssl='false'])
Create a link to an entry's or page's comments section

Parameters:
content - The entry or page to link to its comments
ssl

linkContent

public any linkContent(any content, [boolean ssl='false'], [any format='html'])
Link to a specific content object

Parameters:
content - The content object to link to
ssl
format - The format output of the content default is HTML but you can pass pdf,print or doc.

linkContentSearch

public any linkContentSearch([boolean ssl='false'])
Link to the content search route

Parameters:
ssl

linkEntry

public any linkEntry(any entry, [boolean ssl='false'], [any format='html'])
Link to a specific blog entry's page

Parameters:
entry - The entry to link to
ssl
format - The format output of the content default is HTML bu you can pass pdf,print or doc.

linkEntryWithSlug

public any linkEntryWithSlug(any slug, [boolean ssl='false'], [any format='html'])
Link to a specific entry's page using a slug only

Parameters:
slug - The entry slug to link to
ssl
format - The format output of the content default is HTML bu you can pass pdf,print or doc.

linkHome

public any linkHome()
Create a link to your site root or home page entry point for your blog.


linkPage

public any linkPage(any page, [boolean ssl='false'], [any format='html'])
Link to a specific page

Parameters:
page - The page to link to. This can be a simple value or a page object
ssl
format - The format output of the content default is HTML but you can pass pdf,print or doc.

linkPageRSS

public any linkPageRSS([any category], [boolean comments='false'], [any page], [boolean ssl='false'])
Link to the ContentBox Page RSS Feeds

Parameters:
category - The category to filter on
comments - Page comments or not, defaults to false
page - The page you want to filter on
ssl

linkPageWithSlug

public any linkPageWithSlug(any slug, [boolean ssl='false'], [any format='html'])
Link to a specific page using a slug only

Parameters:
slug - The page slug to link to
ssl
format - The format output of the content default is HTML bu you can pass pdf,print or doc.

linkRSS

public any linkRSS([any category], [any comments='false'], [any entry], [boolean ssl='false'])
Link to RSS feeds that ContentBox generates, by default it is the recent updates feed

Parameters:
category - You can optionally pass the category to filter on
comments - A boolean flag that determines if you want the comments RSS feed
entry - You can optionally pass the entry to filter the comment's RSS feed
ssl

linkSearch

public any linkSearch([boolean ssl='false'])
Link to the search route for this blog

Parameters:
ssl

linkSelf

public any linkSelf()
Create a link to the current page/entry you are on


linkSiteRSS

public any linkSiteRSS([any category], [boolean comments='false'], [string slug], [boolean ssl='false'])
Link to the ContentBox Site RSS Feeds

Parameters:
category - The category to filter on
comments - Do comments RSS feeds
slug - The content slug to filter on when using comments
ssl

linkToParentPage

public any linkToParentPage([any page], [any text=''])
Create an href to a page's parent

Parameters:
page - Optional page to create link for, else look for current page
text - The optional text to use for the link, else it uses the page's title

mainView

public any mainView()
Render the incoming event's main view, basically a proxy to ColdBox's renderView().


minify

public any minify(any assets)
Prepare source(s) statements using our fabulous jsmin compressor

Parameters:
assets - A list of js or css files to compress and add to the page. They will be concatenated in order

minifyClearCache

public CBHelper minifyClearCache()


minifyToHead

public CBHelper minifyToHead(any assets)
Prepare source(s) statements using our fabulous jsmin compressor and send them to the head section

Parameters:
assets - A list of js or css files to compress and add to the page. They will be concatenated in order

quickAvatar

public any quickAvatar(any author, [numeric size='25'])
Renders out an author's avatar

Parameters:
author - The author object to render an avatar from
size - The size of the gravatar, by default we use 25 pixels

quickCategories

public any quickCategories([any template='category'], [any collectionAs='category'], [any args='[runtime expression]'])
Render out categories anywhere using ColdBox collection rendering

Parameters:
template - The name of the template to use, by default it looks in the 'templates/category.cfm' convention, no '.cfm' please
collectionAs - The name of the iterating object in the template, by default it is called 'category
args - A structure of name-value pairs to pass to the template

quickCategoryLinks

public any quickCategoryLinks(any entry)

Parameters:
entry

quickCommentForm

public any quickCommentForm(any content)
quickCommentForm will build a standard ContentBox Comment Form according to the CommentForm widget

Parameters:
content - The content this comment form will be linked to, page or entry

quickComments

public any quickComments([any template='comment'], [any collectionAs='comment'], [any args='[runtime expression]'])
Render out comments anywhere using ColdBox collection rendering

Parameters:
template - The name of the template to use, by default it looks in the 'templates/comment.cfm' convention, no '.cfm' please
collectionAs - The name of the iterating object in the template, by default it is called 'comment
args - A structure of name-value pairs to pass to the template

quickCustomFields

public any quickCustomFields()
Render out custom fields for the current content


quickEntries

public any quickEntries([any template='entry'], [any collectionAs='entry'], [any args='[runtime expression]'])
Render out entries in the home page by using our ColdBox collection rendering

Parameters:
template - The name of the template to use, by default it looks in the 'templates/entry.cfm' convention, no '.cfm' please
collectionAs - The name of the iterating object in the template, by default it is called 'entry
args - A structure of name-value pairs to pass to the template

quickEntry

public any quickEntry([any template='entry'], [any collectionAs='entry'], [any args='[runtime expression]'])
Render out an entry using your pre-defined 'entry' template

Parameters:
template - The name of the template to use, by default it looks in the 'templates/entry.cfm' convention, no '.cfm' please
collectionAs - The name of the iterating object in the template, by default it is called 'entry
args - A structure of name-value pairs to pass to the template

quickLayout

public any quickLayout(any layout, [any view=''], [any module='contentbox'], [any args='[runtime expression]'], [any viewModule=''], [any prePostExempt='false'])
QuickLayout is a proxy to ColdBox's renderLayout method with the addition of prefixing the location of the layout according to the layout theme you are using. All the arguments are the same as renderLayout()'s methods

Parameters:
layout
view
module
args
viewModule
prePostExempt

quickPaging

public any quickPaging()
Render out paging for blog entries only


quickSearchForm

public any quickSearchForm()
quickSearchForm will build a standard ContentBox Content Search Form according to the SearchForm widget


quickSearchPaging

public any quickSearchPaging()
Render out paging for search content


quickView

public any quickView(any view, [any cache='false'], [any cacheTimeout], [any cacheLastAccessTimeout], [any cacheSuffix], [any module='contentbox'], [any args], [any collection], [any collectionAs], [any prepostExempt])
QuickView is a proxy to ColdBox's renderview method with the addition of prefixing the location of the view according to the layout theme you are using. All the arguments are the same as renderView()'s methods

Parameters:
view
cache
cacheTimeout
cacheLastAccessTimeout
cacheSuffix
module
args
collection
collectionAs
prepostExempt

rootMenu

public any rootMenu([any excludes=''], [any type='ul'], [any separator=''], [any levels='1'], [any parentClass='parent'], [any activeClass='active'])
Render out a quick menu for root level pages

Parameters:
excludes - The list of pages to exclude from the menu
type - The type of menu, valid choices are: ul,ol,li,data,none
separator - Used if type eq none, to separate the list of href's
levels - The number of levels to nest hierarchical pages, by default it does only 1 level, * does all levels
parentClass - The name of the CSS class to attach to the menu
  • element when it has nested elements, by default it is 'parent
  • activeClass - The name of the CSS class to attach to the menu
  • element when that element is the current page you are on, by default it is 'active

  • searchTermExists

    public boolean searchTermExists()


    sep

    private any sep()
    Get the site URL separator


    setNextModuleEvent

    public any setNextModuleEvent(string module, [string event], [any queryString=''], [boolean addToken='false'], [any persist], [struct persistStruct], [boolean ssl='false'], [boolean postProcessExempt='false'], [numeric statusCode])
    SetNextEvent For ContentBox Modules

    Parameters:
    module - The module to link this URL to
    event - The handler action combination to link to
    queryString - The query string to append in SES format
    addToken
    persist
    persistStruct
    ssl - Create the link in SSL or not
    postProcessExempt
    statusCode

    setting

    public any setting(any key, [any value])

    Parameters:
    key
    value

    siteBaseURL

    public any siteBaseURL()


    siteDescription

    public any siteDescription()


    siteEmail

    public any siteEmail()


    siteKeywords

    public any siteKeywords()


    siteName

    public any siteName()


    siteOutgoingEmail

    public any siteOutgoingEmail()


    siteRoot

    public any siteRoot()


    siteTagLine

    public any siteTagLine()


    stripHTML

    public any stripHTML(any stringTarget)
    utility to strip HTML

    Parameters:
    stringTarget

    subPageMenu

    public any subPageMenu([any page], [any excludes=''], [any type='ul'], [any separator=''], [boolean showNone='true'], [any levels='1'], [any parentClass='parent'], [any activeClass='active'], [any activeShowChildren='false'])
    Create a sub page menu for a given page or current page

    Parameters:
    page - Optional page to create menu for, else look for current page, this can be a page object or a page slug
    excludes - The list of pages to exclude from the menu
    type - The type of menu, valid choices are: ul,ol,li,none
    separator - Used if type eq none, to separate the list of href's
    showNone - Shows a 'No Sub Pages' message or not
    levels - The number of levels to nest hierarchical pages, by default it does only 1 level, * does all levels
    parentClass - The name of the CSS class to attach to the menu
  • element when it has nested elements, by default it is 'parent
  • activeClass - The name of the CSS class to attach to the menu
  • element when that element is the current page you are on, by default it is 'active
  • activeShowChildren - If true, then we will show the children of the active menu element, else we just show the active element

    widget

    public any widget(any name, [struct args='[runtime expression]'])
    Execute a widget's renderit method

    Parameters:
    name - The name of the installed widget to execute
    args - The argument collection to pass to the widget's renderIt() method

    widgetRoot

    public any widgetRoot()


    ContentBox Core API 1.6.0